knitr::opts_chunk$set( collapse = TRUE, comment = "#>", fig.path = "README-" )
The goal of raodn is to ...
You can install raodn from github with:
# install.packages("devtools") devtools::install_github("mdsumner/raodn")
This is a basic example that gets some Argo data.
library(raodn) ## read Argo data from AODN example("read_aodn_csv") library(ggplot2) ggplot(d[d$pres < 100, ]) + aes(longitude, latitude, col = psal) + geom_point() ggplot(d) + aes(psal, -pres, col = temp) + geom_point() + facet_wrap(~platform_number)
u <- "http://geoserver-123.aodn.org.au/geoserver/ows?typeName=imos:argo_profile_data&SERVICE=WFS&outputFormat=JSON&REQUEST=GetFeature&VERSION=1.0.0&CQL_FILTER=INTERSECTS(position%2CPOLYGON((147.07397460938%20-44.989990234375%2C147.07397460938%20-43.891357421875%2C148.15063476563%20-43.891357421875%2C148.15063476563%20-44.989990234375%2C147.07397460938%20-44.989990234375)))%20AND%20oxygen_sensor%20%3D%20true" system(sprintf("ogrinfo '%s'", u)) library(rgdal) x <- readOGR(u, "OGRGeoJSON") u <- "http://geoserver-123.aodn.org.au/geoserver/ows?typeName=imos:argo_profile_data&SERVICE=WFS&outputFormat=csv&REQUEST=GetFeature&VERSION=1.0.0" u <- "http://geoserver-123.aodn.org.au/geoserver/ows?typeName=imos:argo_profile_data&SERVICE=WFS&outputFormat=csv&REQUEST=GetFeature&VERSION=1.0.0&CQL_FILTER=INTERSECTS(position%2CPOLYGON((147.07397460938%20-44.989990234375%2C147.07397460938%20-43.891357421875%2C148.15063476563%20-43.891357421875%2C148.15063476563%20-44.989990234375%2C147.07397460938%20-44.989990234375)))%20AND%20oxygen_sensor%20%3D%20true" u <- "http://geoserver-123.aodn.org.au/geoserver/ows?typeName=imos:argo_profile_data&SERVICE=WFS&outputFormat=JSON&REQUEST=GetFeature&VERSION=1.0.0&CQL_FILTER=INTERSECTS(position%2CPOLYGON((147.07397460938%20-44.989990234375%2C147.07397460938%20-43.891357421875%2C148.15063476563%20-43.891357421875%2C148.15063476563%20-44.989990234375%2C147.07397460938%20-44.989990234375)))%20AND%20oxygen_sensor%20%3D%20true" x <- readLines(u) library(rgdal) ogrListLayers(u)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.