Skip to main content
Solved

Hello, thanks in advance for help. I have a shapefile with no .prj. I think it was derived from a CAD file because the shapefile has coordinates of 0,0 in the approximate center of the bounding box.


Forum|alt.badge.img

The extents of the shapefile bounding box are -100 (left) and 100 (right) and -200 (bottom) and 200 (top). Since there is no prj I don't know the units, but I do I know the shapefile is supposed to be a UTM 12 north map projection and I know all the other CRS parameters (so I am able to create the correct prj for the shapefile). In addition to this, I know the x-offset and y-offset and scale values that must be applied to the shapefile. My question: how do I apply the offset and scale to the shapefile? I believe these offset and scale values were derived when the file was converted from CAD. Thanks!

Best answer by virtualcitymatt

You need to apply the offset with an Offseter transformer and the scale with a Scaler transformer.

So you read in your shapefile, apply the scale, then apply the Offset. After that you can use a coordinatesystemsetter transformer to set the coordinate system and then just right it out back to a shapefile. This should also just create a proper prj file too.​

Perhaps there's a better way but this is how I'd do it.​

View original
Did this help you find an answer to your question?

2 replies

virtualcitymatt
Celebrity
Forum|alt.badge.img+34
  • Celebrity
  • Best Answer
  • October 16, 2021

You need to apply the offset with an Offseter transformer and the scale with a Scaler transformer.

So you read in your shapefile, apply the scale, then apply the Offset. After that you can use a coordinatesystemsetter transformer to set the coordinate system and then just right it out back to a shapefile. This should also just create a proper prj file too.​

Perhaps there's a better way but this is how I'd do it.​


Forum|alt.badge.img
  • Author
  • October 19, 2021

Hi virtualcitymatt, thanks for the help. I wasn't aware of the Offseter transformer. Yes, that works fine! Mark


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings