Skip to content

Commit 847b49e

Browse files
committed
FEW MORE CHANGES
1 parent c508c55 commit 847b49e

File tree

2 files changed

+5
-12
lines changed

2 files changed

+5
-12
lines changed

v1.0.0

Whitespace-only changes.

vignettes/hdar.Rmd

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ To search for data in the HDA service, you need to create a query template. Manu
126126

127127
The `generate_query_template` function generates a template of a query for a specified dataset. This function fetches information about existing parameters, default values, etc., from the `/queryable` endpoint of the HDA service.
128128

129-
#### Example: Generating a Query Template
129+
#### Example: Generating a Query
130130

131131
Here is an example of how to generate a query template for the dataset with the ID "EO:EEA:DAT:CLMS_HRVPP_ST":
132132

@@ -193,12 +193,10 @@ $bbox
193193
[1] -180 -90 180 90
194194
```
195195

196-
## Using the Generated Query Template
196+
## Modify and use the generated Query Template
197197

198198
You can and should customize the generated query template to fit your specific needs. Fields starting with '\_\_###' are placeholder values indicating possible values, but if unchanged it will be stripped off before sending the query to the HDA service.
199199

200-
#### Example: Using the Query Template in a Search
201-
202200
Here is an example of how to use the query template in a search:
203201

204202
```{r, eval = FALSE}
@@ -251,8 +249,6 @@ To search for data in the HDA service, you can use the `search` function provide
251249

252250
The `search` function takes a query and an optional limit parameter, which specifies the maximum number of results you want to retrieve. The function only searches for data and does not download it. The output of this function is an instance of the `SearchResults` class.
253251

254-
#### Example: Searching for Data
255-
256252
Here is an example of how to search for data using a query and limit the results to 5:
257253

258254
```{r, eval = FALSE}
@@ -269,12 +265,10 @@ sapply(matches$results,FUN = function(x){x$id})
269265
[9] "ST_20180521T000000_S2_T32TPS-010m_V101_PPI"
270266
```
271267

272-
## Downloading the Found Results
268+
## Downloading the files
273269

274270
The `SearchResults` class has a public field results and a method called download that is responsible for downloading the found data. The `download()` function takes an output directory (which is created if no existing) and the optional parameter `selected_indexes` to specify which files to download.
275271

276-
#### Example: Downloading results
277-
278272
```{r, eval = FALSE}
279273
# Assuming 'matches' is an instance of SearchResults obtained from the search
280274
odir <- "~/deleteme"
@@ -292,9 +286,7 @@ y
292286
[1] "[Download] Downloading file 8/9"
293287
[1] "[Download] Downloading file 9/9"
294288
[1] "[Download] DONE"
295-
```
296-
#### Example: Downloading files
297-
```{r, eval = FALSE}
289+
298290
# Assuming 'matches' is an instance of SearchResults obtained from the search
299291
list.files(odir)
300292
[1] "ST_20180301T000000_S2_T32TPS-010m_V101_PPI.tif" "ST_20180311T000000_S2_T32TPS-010m_V101_PPI.tif"
@@ -305,3 +297,4 @@ list.files(odir)
305297
306298
unlink(odir,recursive = TRUE)
307299
```
300+

0 commit comments

Comments
 (0)