how areas are calculated on Saiku?

Does the exactitude of the result depends or not on the density of the Sampling ?

Thanks

asked 24 Apr '15, 11:17

imen's gravatar image

imen
11223
accept rate: 0%

edited 22 Sep '15, 15:45

Open%20Foris's gravatar image

Open Foris ♦♦
1.0k5714


Hello Ulpu,

We have changed the way that the expansion factors are calculated. From now on you will be able to mix the attributes so that for instance you might have several strata per province. The file that should be used is called areas_per_attribute.csv and in this CSV you must have a column per attribute that will be used ( using the name of the attribute as the name of the header) followed by the area and the "weight" of the plot.

Take for instance the Drylands Monitoring and Assessment project. In this project each plot has a "From CSV" type of attributes called dryland_region and dryland_category. For each dryland "region"( like Sahel or Central Asia) there are plots situated in different "dryland strata"(categories like Arid, Semiarid and so on). So the CSV with the areas and weights of the plots (per combination of attributes) are the combination of these values (CHECK THE NAMES OF THE HEADERS! ):

dryland_region,dryland_category,area,weight
Sahel,Hyperarid,163953200,3
Sahel,Arid,201048300,2
Sahel,Semiarid,154001400,1
Sahel,Dry subhumid,99204200,1
HornAfrica,Hyperarid,82949500,3
HornAfrica,Arid,144818400,2
HornAfrica,Semiarid,143918800,1
HornAfrica,Dry subhumid,48291800,1
NorthernAfrica,Hyperarid,416110100,3
NorthernAfrica,Arid,96377700,2
NorthernAfrica,Semiarid,37256500,1
NorthernAfrica,Dry subhumid,15009000,1
...

So if in your project you have an attribute called country then you should include an areas_per_attribute.csv file inside the CEP file that would look like this (in this example the country will only be Zanzibar):

country,area,weight
Zanzibar,150733,1

Then put this file that you generated inside the CEP file that was generated using Collect designer (you can open it as a ZIP file)

Hope this helped!

permanent link

answered 15 Jul '15, 14:04

Open%20Foris's gravatar image

Open Foris ♦♦
1.0k5714
accept rate: 10%

edited 22 Sep '15, 15:46

Dear Imem,

As we speak we are working on a different way of calculating areas, but for older versions of Collect Earth surveys the area calculations are rather straight forward, here is an attempt to explain it:

Inside a Collect Earth project file there is a file called region_areas.csv. In the case of Tunisia this file looks like this :

Province,Plot File,Area(HA),Weight
ariana,,45000,1
ben_arous,,66200,1
bizerte,,355000,1
beja,,358700,1
gabes,,747000,1
gafsa,,758100,1
jendouba,,329400,1
kairouan,,645100,1
kasserine,,825000,1
... and so on

The first column is the name of the region, the second column is the name of the Plot File that contained the plot information (it can be empty if the region name was collected), the third column is the total area of the Region in Hectares and finally the last column is the weight of the plot (by default it is 1 ).

To calculate the expansion factor of a plot (the area in hectares that the plot represent) Collect Earth divides the Area of the region (provided as we saw in the region_areas.csv) by the number of plots within the region. As we are using systematic sampling designs the expansion factor would be the same for all of the plots within a region. When Saiku performs calculations using the Area measure what is does is to add the expansion factors of the plots in the results.

The weight of a plot is quite simple to calculate too, if you have defined that all the regions have a sampling design (grid) of 10 by 10 kilometers and the region of Jendouba (because is desertic or some other reason ) has a sampling design with plots that are separated by 20 by 20 kilometers this means that the weight of the plots in Jendouba are four times as much as the weights of the plots of the other provinces --> There are four times less plots in the province of Jendouba ( per square kilometer ) as in the other provinces, thus the results for plots inside this province have to weight four times as much. The resulting region_areas.csv file should then be :

Province,Plot File,Area(HA),Weight
ariana,,45000,1
ben_arous,,66200,1
bizerte,,355000,1
beja,,358700,1
gabes,,747000,1
gafsa,,758100,1
jendouba,,329400,4
kairouan,,645100,1
kasserine,,825000,1
... and so on

Notice how now all the provinces have a weight of 1 except Jendouba that has a weight of 4.

This approach to calculate weights and areas assumes that your survey has a "region" attribute. Most of the surveys that we have worked with have it. Usually the actual value of the region per each plot comes directly from the sampling design ( check the CSV/CED files where the plot locations are defined and you will notice a region column) so that the operators don't need to fill this information and it is handled directly by Collect Earth.

In the future we will have a similar mechanism to calculate the expansion factors and measures that does not force you to use the "region" attribute but instead let you calculate these expansion factors based in other attributes such as country or ecologic zone.

Did this answer your question?

permanent link

answered 27 Apr '15, 12:59

Open%20Foris's gravatar image

Open Foris ♦♦
1.0k5714
accept rate: 10%

Hi, I created a custom project file with Collect and added a sampling grid and region_areas.csv. Collecting data works fine but Saiku is not calculating the areas. The error seems to be “no such column: plot.expansion_factor”. How could I fix this?

permanent link

answered 13 Jul '15, 14:35

ulpu's gravatar image

ulpu
232911
accept rate: 0%

Hi Ulpu, can you check if there are any error messages relevant to this on the log??

Collect Earth -> Help -> Open Application log file

The plot_expansion column should always be added to the plot table, so unless the process to generate the Saiku database went wrong then it should be present...

Also please share your CEP file so I can take a look.

/Alfonso

permanent link

answered 14 Jul '15, 12:20

Open%20Foris's gravatar image

Open Foris ♦♦
1.0k5714
accept rate: 10%

Thanks a lot! This helps.

A follow-up question: is it possible to edit which Dimensions I see in Saiku and the default measure (now it's area)?

permanent link

answered 16 Jul '15, 13:44

ulpu's gravatar image

ulpu
232911
accept rate: 0%

Hi Ulpu,

You need to edit the file called collectEarthCubes.xml.fmt and change the names of the Dimensions and so on there.

Also by default Saiku uses the first masseur that is defined in the cube Schema. So the thing to do is just to move up the line that contains of Plot Count above the area measure.

Happy collecting!

permanent link

answered 16 Jul '15, 14:27

Open%20Foris's gravatar image

Open Foris ♦♦
1.0k5714
accept rate: 10%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×42

question asked: 24 Apr '15, 11:17

question was seen: 11,506 times

last updated: 22 Sep '15, 15:46