Closed bbest closed 2 years ago
Now with @cdobbelaere...
Copied /share/github/apps_dev
to /share/github/apps_cdob
and created a branch projects-cdob
. Then turned on Shiny app for public viewing (although launching in RStudio is better for debugging):
# change directory
cd /srv/shiny-server
# switch user and do (sudo) symbolically link (ln -s) the github folder to the shiny app URL
sudo ln -s /share/github/apps_cdob/report-v2 report-v2-cdob
Then app served at https://shiny.marineenergy.app/report-v2-cdob/.
leafletProxy("prj_map", data = filteredData()) %>%
clearShapes() %>%
addCircles(radius = ~10^mag/10, weight = 1, color = "#777777",
fillColor = ~pal(mag), fillOpacity = 0.7, popup = ~paste(mag)
References:
Next step is to similarly proxy leaflet Timeline plot around here:
load_projects()
plot_projects()
Tips:
n_riv
, n_tid
and n_wav
Plotly projects timeline now updates according to selected technology.
Ex. 1 Initial plot:
Ex. 2 Filtering by tidal & wave energy:
Ex. 3 Filtering by riverine & tidal energy:
TODO: filter by Technology
https://github.com/marineenergy/apps/blob/48a40ed0f1a9dffbd15b69d3b7efac3e3764b78f/report-v2/global.R#L226
which calls:
https://github.com/marineenergy/apps/blob/48a40ed0f1a9dffbd15b69d3b7efac3e3764b78f/scripts/shiny_report.R#L50-L118
and eventually based on ui.R, these get called in the server.R:
https://github.com/marineenergy/apps/blob/48a40ed0f1a9dffbd15b69d3b7efac3e3764b78f/report-v2/server.R#L130-L139
and finally, these are the functions that do the mapping and plotting of the initial outputs:
https://github.com/marineenergy/apps/blob/48a40ed0f1a9dffbd15b69d3b7efac3e3764b78f/scripts/shiny_report.R#L120-L288
To subsequently filter based on Technology Tags of Interactions, I think we want to use a Proxy for both leaflet map and plotly timeline, similar to here:
https://github.com/marineenergy/apps/blob/48a40ed0f1a9dffbd15b69d3b7efac3e3764b78f/report-v2/server.R#L146-L159