@@ -33,7 +33,7 @@ Create a file that contains your API key. If you have signed up for access to th
3333
3434# Example with the public key:
3535writeLines('9999999999999999999999999999999999999999',
36- con = 'traits/ .betykey_public')
36+ con = '.betykey_public')
3737```
3838
3939#### R - using the traits package
@@ -51,7 +51,7 @@ sorghum_info <- betydb_query(table = 'species',
5151 api_version = 'v1',
5252 limit = 'none',
5353 betyurl = "https://terraref.ncsa.illinois.edu/bety/",
54- key = readLines('traits/ .betykey', warn = FALSE))
54+ key = readLines('.betykey', warn = FALSE))
5555
5656```
5757
@@ -62,7 +62,7 @@ Notice all of the arguments that the `betydb_query` function requires? We can ch
6262
6363
6464``` {r set-up, echo = TRUE}
65- options(betydb_key = readLines('traits/ .betykey', warn = FALSE),
65+ options(betydb_key = readLines('.betykey', warn = FALSE),
6666 betydb_url = "https://terraref.ncsa.illinois.edu/bety/",
6767 betydb_api_version = 'v1')
6868```
@@ -71,18 +71,18 @@ Now the same query can be reduced to:
7171
7272``` {r query-species-reduce, echo = TRUE, results = FALSE}
7373sorghum_info <- betydb_query(table = 'species',
74- genus = "Sorghum",
75- limit = 'none')
74+ genus = "Sorghum",
75+ limit = 'none')
7676```
7777
7878### Time series of height
7979
8080Now let's query some trait data.
81- ``` {r sv_area , echo = TRUE, results = FALSE}
82- sorghum_height <- betydb_query(table = 'search',
83- trait = "canopy_height",
84- site = "~Season 6",
85- limit = 'none')
81+ ``` {r canopy_height , echo = TRUE, results = FALSE, cache = TRUE }
82+ sorghum_height <- betydb_query(table = 'search',
83+ trait = "canopy_height",
84+ sitename = "~Season 6",
85+ limit = 'none')
8686```
8787
8888``` {r}
0 commit comments