Skip to main content
Calculating the percentage of registered and non-registered land in each governorate on the Area A, Area B and Area C

 

 

 

I couldn’t figure out the best practice to calculating the percentage of registered and non-registered land in each governorate on the Area A, Area B and Area C

 

 

 

In the ArcGIS, for example, this sort of work is done as shown in the following model.

 

 

 

 

 

Which equivalent tools in FME that can be used to calculate this values?

 

 

 

The data is store in the link below:

 

http://www.mediafire.com/download/a674hybiyc7v1b8/E1.gdb.rar

 

 

Thanks in advance
I have not reviewed your data as it is contains in rar format... Based on the understadning on the question, the below 3 transformers are required...

 

1. FeatureMerger

 

2. Statistics Calculator

 

3. Expression Evaluator

 

 

Based on the output of the data, further transformers may or may not be required
Hi,

 

 

"Area_A", "Area_B" and "Area_C" are attribute values stored in the ABC table. I think the question point is how to change the them to field names in the result table.

 

I would use the BulkAttributeRenamer and the Aggregator to do that.

 

 

(1) Clip the Governorates areas by the LangRegistration areas (merge attributes).

 

(2) Clip the resulting Inside areas by the ABC_Areas (merge attributes).

 

(3) Calculate the areas of the clipped areas with the AreaCalculator.

 

(4) Use the BulkAttributeRenamer to rename the area attribute.

 

- Rename: Selected Attributes

 

- Selected Attribute: _area (attribute that stores the area)

 

- Action: Regular Expression Replace

 

- Text To Find: .+

 

- String: ABC (attribute that stores "Area_A", "Area_B" or "Area_C")

 

(7) Aggregate the features with the Aggregato.

 

- Group By: Name, Registration_English

 

- Keep Input Attributes: Yes

 

(6) Expose the attribute names ("Area_A", "Area_B" and "Area_C")

 

(7) Use the NullAttributeMapper to replace area attribute with 0 if it was missing.

 

(8) Calculate percentages for "Area_A", "Area_B" and "Area_C" with the AttributeCreator.

 

(9) Optionally remove unnecessary attributes (AttributeRemover or AttributeKeepre); form the attribute values by the preferable format (StringFormatter); sort the features (Sorter).

 

 

The data flow looks like this.

 

 

Result

 

 

 

Takashi
In this case, you can replace (3) AreaCalculator and (4) BulkAttributeRenamer with this AttributeCreator.

 


Thanks very much Takashi,

 

 

but it's produce only two values ,, see attached

 

 

what might be the issue here?
I suspect the "Group By" parameter of the Aggregator is improper.

 

Group By: Name  Registration_English
yes thats right but the last thing in the use of NullAttributeMapper to replace area attribute with 0 if it was missing it doesn't work with me maybe i do somthing wrong

 


The area attribute has been renamed already.  Set "Area_A", "Area_B" and "Area_C" to the Selected Attributes parameter.
yes .. thank you very much Takashi

 

thanks alot for your help

Reply