NewGraphEnvironment / fish_passage_skeena_2021_reporting

https://newgraphenvironment.github.io/fish_passage_skeena_2021_reporting/
Creative Commons Zero v1.0 Universal
0 stars 2 forks source link

make an array for species_code for mapping the hab_fish_collect files #12

Closed NewGraphEnvironment closed 2 years ago

NewGraphEnvironment commented 2 years ago

here is a start.

hab_fish_collect_array <- hab_fish_collect %>%
  select(-species) %>%
  pivot_wider(id_cols = reference_number:utm_northing, names_from = 'site_id', values_from = "species_code")
NewGraphEnvironment commented 2 years ago

@smnorris - does this work ? It puts all the species codes in one column as a string off the bat but looks similiar in structure to FISS fish observations bcfp in Q.... Labels don't quite perform the same for me though (maybe because field 'Type name' is 'String' vs. 'Text'?) so I wonder if we should just be using original long format (hab_fish_collect) and transforming in postgres

smnorris commented 2 years ago

That should work, QGIS can split the labels at the spaces. It is pretty convenient to simply point QGIS to the geojson on GH for the mapping - I'd prefer not to load to postgres unless there is a need.

NewGraphEnvironment commented 2 years ago

nice. See if it works for you. I can't seem to get the labels to wrap..(maybe because field 'Type name' is 'String' vs. 'Text'?)

smnorris commented 2 years ago

2nd tab in the labelling interface, "Wrap on character" One space between species would be better, it is newlining on each space

Screen Shot 2022-05-03 at 9 07 47 AM