Hi @richard_che , if the input attribute value was 100, for instance, you need to generate 100 (exactly or approximately?) points inside the polygon?
Hi @richard_che , if the input attribute value was 100, for instance, you need to generate 100 (exactly or approximately?) points inside the polygon?
I guess if it was a close approximation that would work too if it means an easier setup for this kind of process, the exact amount would be preferred
A possible approach I can think of is: generate grid points which covers the input area, clip the points by the area, then select required number of points randomly with the Sampler. Spacing of the grid should be enough small so that the required number of points will be within the area.
See the attached workspace example to learn more.
Hope this helps.
A possible approach I can think of is: generate grid points which covers the input area, clip the points by the area, then select required number of points randomly with the Sampler. Spacing of the grid should be enough small so that the required number of points will be within the area.
See the attached workspace example to learn more.
Hope this helps.
Hi Takashi,
Thank you so much for taking the time to help me out with this. I'm sorry I should have communicated better, I meant to say I'm look to use the attribute field population (of each polygon) as the value to auto generate the points based on the population value.
So Although the population for 1 polygon may be 100 where I would want 100 points generated spaced out in that polygon, another polygon may have a population of 263 where I would want 263 points generated spaced out in that polygon.
In total there is 100 polygons each with a different population value that I would like to use as the input to determine how many points need to be generated for each polygon.
I attempted to do this with the file you kindly provided, however its centered around a fixed input $(NUM_POINTS) which cannot be modified to a field value from my understanding.
Hi Takashi,
Thank you so much for taking the time to help me out with this. I'm sorry I should have communicated better, I meant to say I'm look to use the attribute field population (of each polygon) as the value to auto generate the points based on the population value.
So Although the population for 1 polygon may be 100 where I would want 100 points generated spaced out in that polygon, another polygon may have a population of 263 where I would want 263 points generated spaced out in that polygon.
In total there is 100 polygons each with a different population value that I would like to use as the input to determine how many points need to be generated for each polygon.
I attempted to do this with the file you kindly provided, however its centered around a fixed input $(NUM_POINTS) which cannot be modified to a field value from my understanding.
OK. I updated the workspace example so that you can specify the number of points with a feature attribute.
See the attachment.
Hi Takashi,
Thank you so much for taking the time to help me out with this. I'm sorry I should have communicated better, I meant to say I'm look to use the attribute field population (of each polygon) as the value to auto generate the points based on the population value.
So Although the population for 1 polygon may be 100 where I would want 100 points generated spaced out in that polygon, another polygon may have a population of 263 where I would want 263 points generated spaced out in that polygon.
In total there is 100 polygons each with a different population value that I would like to use as the input to determine how many points need to be generated for each polygon.
I attempted to do this with the file you kindly provided, however its centered around a fixed input $(NUM_POINTS) which cannot be modified to a field value from my understanding.
This is so perfect!!
Thank you very much Takashi, I really appreciate you doing this for me.
Hi, is there a possibility to have the attachment file, please? I encountered the same issue.
You’re welcome