tutorials:analyse-fastrak-in-r
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
tutorials:analyse-fastrak-in-r [2025/06/27 15:20] – [Import] t | tutorials:analyse-fastrak-in-r [2025/06/27 15:57] (current) – removed t | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Analyse structural FASTRAK data in R ====== | ||
- | There exists the rare case that you might want to conduct some statistical analysis on the structure of your simulated or measured plant outside of XL and GroIMP. GroIMP' | ||
- | |||
- | Here, we present an example on how to export structures from GroIMP and how to analyze them in R. | ||
- | |||
- | ===== Requirements ===== | ||
- | * GroIMP " | ||
- | * GroIMP " | ||
- | * Some recent version of R | ||
- | * R-library " | ||
- | |||
- | ===== GroIMP import & export===== | ||
- | ==== Import ==== | ||
- | |||
- | When using FASTRAK data, you can open a new RGG project and simply import your file using Object -> Insert File / Insert File to RGG. This required the fastrakReader plugin. The difference is that if you insert to RGG, the file will be imported under the RGG Root instead of under Node.0. For our example here, both are equivalent. Note that your data might be scaled in an unexpected way relative to your GroIMP project. In the picture below is an example of FASTRAK data inserted in a New RGG project, note the size of the FASTRAK tree relative to the " | ||
- | |||
- | {{: | ||
- | |||
- | If you want to delete this structure, you can do Edit -> Clear Project Graph (which will remove everything, not only the thing you just imported). | ||
- | |||
- | Using the color() method below, you can color your measured FASTRAK data based on branch orders: | ||
- | |||
- | {{: | ||
- | |||
- | As you can see, there is a possible measurement error here: One branch is colored in blue, which means it is of order 3, but it should probably be order 2. This is because the fastrakReader has to infer the topology of the structure based on the relative position of segments to each other. In this case, this segment happens to start closer to the other branch than to its actual mother segment: | ||
- | |||
- | {{: | ||
- | |||
- | <code java> | ||
- | public void color (){ | ||
- | [ (*f: | ||
- | (*f: | ||
- | (*f: | ||
- | (*f: | ||
- | (*f: | ||
- | ]} | ||
- | </ | ||
- | |||
- | |||
- | |||
tutorials/analyse-fastrak-in-r.1751030423.txt.gz · Last modified: 2025/06/27 15:20 by t