trias-project / alien-species-checklist

🐞 Proof of concept for a checklist of alien species in Belgium
MIT License
3 stars 2 forks source link

Create chart for pathway counts #67

Closed peterdesmet closed 5 years ago

peterdesmet commented 8 years ago
  1. From concatenated.tsv
  2. Add speciesKey for acceptedKey (use GBIF services)
  3. Group # of unique speciesKey by pathway (note: currently ' | ' separated)
  4. Order pathways in main and sub categories according to CBD
  5. Create bar chart for number of species.
peterdesmet commented 8 years ago

You can create this as a public gist.

timadriaens commented 8 years ago

Some more specifics on what we need exactly:

Arial 11 Lines 1.5 (no lines around bar charts) Colors: use following rgb values

image

stijnvanhoey commented 8 years ago

Tim, los van de styling die ik nog zal uitvoeren, zijn dit (conceptueel gezien) de figuren die je wil:

Telling per categorie: category_count

Telling per subcategorie: subcategory_count

Of wil je die op 1 figuur, met telkens de subcategorie in verschillende kleuren voor iedere categorie?

timadriaens commented 8 years ago

Something like this. Not sure yet where I want to go with "to be determined by experts" (for now, maybe to be merged with unknown or just left out). I wil provide dutch translation in the excelsheet with the cbd categories so we can have both languages:

figuur2

timadriaens commented 8 years ago

or if you share the flat table with the data, i'll do it in r and share the script

stijnvanhoey commented 8 years ago

Sounds like a good idea keeping away redundant work (and I'm a fan of ggplot); file is here: https://github.com/inbo/alien-species-checklist/blob/master/utilities/viz_pathways/fig_base.tsv

Great if you would share the R-script, I'll integrate it in the notebook when available

peterdesmet commented 8 years ago

Are there still plans to integrate this or can we close this issue?

stijnvanhoey commented 8 years ago

@timadriaens I do not know if you have the R-code still available, but in case you still want to apply the code and create the figure, the output will be moved to the https://github.com/inbo/alien-species-checklist/tree/master/data/interim folder when the structure-branch is merged. Feel free to ask assistance with the R-code

timadriaens commented 8 years ago

@stijnvanhoey here's the r script we used to create the graph grafiek_pathways.zip

stijnvanhoey commented 8 years ago

I adjusted the code, resulting in the following graph:

pathway_graph The code is added to the repo: https://github.com/inbo/alien-species-checklist/blob/structure/src/grafiek_pathways/grafiek_pathways.R

timadriaens commented 8 years ago

can you order the subcategories (x-axis) from high to low number of species within headline categories (release, escape...)?

stijnvanhoey commented 8 years ago

Good comment. Furthermore, I will adapt the graph in order to facilitate the reading of the x-axis by turning it 90 degrees. At the same time, the facet-headers can be rotated as well, making them well-readable too.

stijnvanhoey commented 8 years ago

Something like this? pathway_graph

stijnvanhoey commented 8 years ago

The cumulative numbere of species in function of time, split by habitat is currently formatted as follows: cumulatief_aantal_invasieve

As the combination of cumsum and factor split up resulted in wrong counts (basically double as the next level starts counting at the max of the previous), a workaround was implemented. However, this will probably need alteration in the future.

peterdesmet commented 5 years ago

Closing issue, project is archived. If issue is still relevant, submit to the actively maintained TrIAS indicators