This repository has been archived by the owner on Nov 10, 2017. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 29
/
data-access.html
289 lines (250 loc) · 12.9 KB
/
data-access.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
<!-- Main page starts here -->
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
<meta name="apple-mobile-web-app-status-bar-style" content="black" />
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
<meta name="apple-mobile-web-app-status-bar-style" content="black" />
<link rel="shortcut icon" href="assets/flat-ui/images/favicon.ico">
<link rel="stylesheet" href="assets/flat-ui/bootstrap/css/bootstrap.css">
<link rel="stylesheet" href="assets/flat-ui/css/flat-ui.css">
<link rel="stylesheet" href="assets/common-files/css/icon-font.css">
<link rel="stylesheet" href="assets/common-files/css/animations.css">
<link rel="stylesheet" href="static/css/style.css">
<link rel="stylesheet" href="static/css/header11.css">
<link rel="stylesheet" href="static/css/github.css">
<script type="text/javascript" src="//use.typekit.net/djn7rbd.js"></script>
<script type="text/javascript">try{Typekit.load();}catch(e){}</script>
<script src="static/highlight.pack.js"></script>
<script>hljs.initHighlightingOnLoad();</script>
<title>rOpenSci - Open Tools for Open Science</title>
</head>
<body>
<div class="page-wrapper"><header class="header-maps">
<!-- This is the navbar -->
<div class="container">
<div class="row">
<div class="navbar col-sm-12" role="navigation">
<div class="navbar-header navlogo">
<button type="button" class="navbar-toggle"></button>
<a class="brand" href="http://karthik.github.io/roweb/"><img src="assets/common-files/img/header/nav_small.png"></a>
</div>
<div class="collapse navbar-collapse pull-right">
<ul class="nav pull-left">
<li><a href="http://karthik.github.io/roweb/">HOME</a></li>
<li><a href="http://karthik.github.io/roweb/blog.html">BLOG</a></li>
<li><a href="http://karthik.github.io/roweb/packages.html">PACKAGES</a></li>
<li><a href="http://karthik.github.io/roweb/community.html">COMMUNITY</a></li>
<li><a href="http://karthik.github.io/roweb/contact.html">CONTACT</a></li>
</ul>
</div>
</div>
</div>
</div>
<!-- end navbar above -->
<div class="header-background"></div>
</header>
<!-- Everything from top till here should go in top header.template -->
<section class="header-maps-sub v-center" id="hero">
<div class="background"> </div>
<div>
<div class="container">
<div class="hero-unit hero-unit-bordered">
<h1>Accessing data</h1>
</div>
</div>
</div>
</section>
<!-- spocc section -->
<section id="main-maps">
<div class="container">
<div class="col-lg-10 col-offset-1">
<h1>Access >1/2 billion species occurrence records</h1>
<p>We have R clients for GBIF, iNaturalist, VertNet, eBird, Ecoengine,
and more. You can access these individually, or with one easy to use
interface in <code>spocc</code>.</p>
<pre><code>library("spocc")
spp <- c('Danaus plexippus','Accipiter striatus','Pinus contorta')
dat <- occ(query = spp, from = 'gbif', gbifopts = list(hasCoordinate=TRUE))</code></pre>
<!-- dat$gbif -->
<!-- <pre><code>Species [Danaus plexippus (500), Accipiter striatus (500), Pinus contorta (500)]
First 10 rows of [Danaus_plexippus]
name longitude latitude prov issues key
1 Danaus plexippus -122.1987 37.70727 gbif cdround,cudc,gass84 899953590
2 Danaus plexippus 172.6022 -43.56203 gbif cdround,cudc,gass84 1038315535
3 Danaus plexippus 172.6054 -43.55472 gbif cdround,cudc,gass84 1038316044
4 Danaus plexippus 175.6724 -40.17824 gbif cdround,cudc,gass84 1038314326
5 Danaus plexippus -101.6510 18.98942 gbif cdround,cudc,gass84 1042814387
6 Danaus plexippus -157.7563 21.40500 gbif cdround,cudc,gass84 891778773
7 Danaus plexippus -157.8044 21.31149 gbif cdround,cudc,gass84 891779783
8 Danaus plexippus -157.7024 21.34359 gbif cdround,cudc,gass84 891779819
9 Danaus plexippus -120.8420 35.32175 gbif cdround,cudc,gass84 891780432
10 Danaus plexippus -116.9956 32.84474 gbif cdround,cudc,gass84 891780781
.. ... ... ... ... ... ...
Variables not shown: datasetKey (chr), publishingOrgKey (chr), publishingCountry (chr), protocol (chr),
lastCrawled (chr), lastParsed (chr), extensions (chr), basisOfRecord (chr), taxonKey (int),
kingdomKey (int), phylumKey (int), classKey (int), orderKey (int), familyKey (int), genusKey (int),
speciesKey (int), scientificName (chr), kingdom (chr), phylum (chr), order (chr), family (chr), genus
(chr), species (chr), genericName (chr), specificEpithet (chr), taxonRank (chr), dateIdentified
(chr), year (int), month (int), day (int), eventDate (chr), modified (chr), lastInterpreted (chr),
references (chr), identifiers (chr), facts (chr), relations (chr), geodeticDatum (chr), class (chr),
countryCode (chr), country (chr), verbatimEventDate (chr), verbatimLocality (chr), rights (chr),
rightsHolder (chr), occurrenceID (chr), taxonID (chr), collectionCode (chr), gbifID (chr),
institutionCode (chr), catalogNumber (chr), datasetName (chr), recordedBy (chr), occurrenceDetails
(chr), eventTime (chr), identifier (chr), identificationID (chr), occurrenceRemarks (chr),
informationWithheld (chr), locality (chr), identificationRemarks (chr), coordinateAccuracy (dbl),
elevation (dbl), elevationAccuracy (dbl), depth (dbl), depthAccuracy (dbl), stateProvince (chr),
county (chr), identifiedBy (chr)
</code>
</pre> -->
<pre><code>
data <- occ2df(dat)
mapleaflet(data = data, dest = ".")
</code>
</pre>
<img src="assets/theme-images/leaflet.png">
</div>
</div>
</section>
<!-- taxize section -->
<section class="content-15 v-center" id="main-maps">
<div class="container">
<div class="col-lg-10 col-offset-1">
<h1>Access millions of taxonomic names</h1>
<p><code>taxize</code> gives you access to ~20 sources of taxonomic data, with
functions to acquire taxonomic classifications, downstream names, taxonomic
synonyms, and more.</p>
<pre><code>
library("taxize")
downstream("Apis", db = 'itis', downto = 'Species', verbose = FALSE
</code></pre>
<pre><code>$Apis
tsn parentname parenttsn taxonname rankid rankname
1 154396 Apis 154395 Apis mellifera 220 Species
2 763550 Apis 154395 Apis andreniformis 220 Species
3 763551 Apis 154395 Apis cerana 220 Species
4 763552 Apis 154395 Apis dorsata 220 Species
5 763553 Apis 154395 Apis florea 220 Species
6 763554 Apis 154395 Apis koschevnikovi 220 Species
7 763555 Apis 154395 Apis nigrocincta 220 Species</code></pre>
</div>
</div>
</section>
<!-- fulltext section -->
<section class="content-15 v-center" id="main-maps">
<div class="container">
<div class="col-lg-10 col-offset-1">
<h1>Access scholarly metadata and text</h1>
<p>We are developing a suite of packages to give access to scholarly metadata and text.
<code>fulltext</code> provides a single, easy to use interface to lots of publishers.
<code>rmetadata</code> does the same for scholarly metadata.</p>
<strong>Search for articles</strong>
<pre><code>ft_search(query='ecology', from='plos')</code></pre>
<pre><code>Query:
[ecology]
Found:
[PLoS: 23517; BMC: 0; Crossref: 0; Entrez: 0; arxiv: 0]
Returned:
[PLoS: 10; BMC: 0; Crossref: 0; Entrez: 0; arxiv: 0]</code></pre>
<strong>Get full text articles</strong>
<pre><code>ft_get(ids='10.1371/journal.pone.0086169', from='plos')</code></pre>
<pre><code>[Docs] 1
[Source] R session
[Size] Min. Length: 111132 - Max. Length: 111132
[IDs] 10.1371/journal.pone.0086169 ...</code></pre>
</div>
</div>
</section>
<!-- Move everything below into a footer.template.
Note: All other footers are out of date and need to be sourced from here -->
<footer class="footer-6">
<div class="container">
<div class="row">
<div class="col-sm-3">
<div><a class="brand" href="http://karthik.github.io/roweb">rOpenSci</a></div>
</div>
<nav>
<div class="col-sm-2">
<h6>About</h6>
<ul>
<li><a href="about.html">About Us</a></li>
<li><a href="about.html#core">Core team</a></li>
<li><a href="about.html#advisors">Advisory board</a></li>
<li><a href="community.html">Community</a></li>
</ul>
</div>
<div class="col-sm-2">
<h6>Work</h6>
<ul>
<li><a href="packages.html">R Packages</a></li>
<li><a href="/blog/">Blog</a></li>
<li><a href="tutorials.html">Tutorials</a></li>
<li><a href="use-cases.html">Use cases</a></li>
<li><a href="resources.html">Resources</a></li>
</ul>
</div>
<div class="col-sm-2">
<h6>Other</h6>
<ul>
<li><a href="contact.html">Contact</a></li>
<li><a href="events.html">Events</a></li>
<li><a href="related_links.html">Related links</a></li>
<li><a href="https://github.com/ropensci">GitHub Org</a></li>
</ul>
</div>
</nav>
<div class="col-sm-3">
<h6>Subscribe</h6>
<!-- start form -->
<form action="http://ropensci.us7.list-manage1.com/subscribe/post?u=c5de56320aeac3ee7cc954ec2&id=d78520d99e" method="post" class="validate" target="_blank">
<div class="input-group">
<input type="email" value="" name="EMAIL" id="mce-EMAIL" placeholder="Email Address" autocapitalize="off" autocorrect="off" class="form-control" required>
<span class="input-group-btn">
<button class="btn" type="button" name="submit">
<span class="fui-arrow-right"> </span>
</button>
</span>
</div>
</form>
<!-- end form -->
<div class="social-btns">
<a href="http://gplus.to/ropensci">
<div class="fui-googleplus"></div>
<div class="fui-googleplus"></div>
</a>
<a href="http://twitter.com/ropensci">
<div class="fui-twitter"></div>
<div class="fui-twitter"></div>
</a>
<a href="https://vimeo.com/91344060">
<div class="fui-vimeo"></div>
<div class="fui-vimeo"></div>
</a>
</div>
</div>
</div>
<div class="row"><p>© rOpenSci, 2014 </p></div>
</div>
</footer>
<!-- Here ends the footer -->
<!-- These are javascript libraries. Move to javascript.template -->
<script src="assets/common-files/js/jquery-1.10.2.min.js"></script>
<script src="assets/common-files/js/jquery.bxslider.min.js"></script>
<script src="assets/common-files/js/jquery.scrollTo-1.4.3.1-min.js"></script>
<script src="assets/flat-ui/js/bootstrap.min.js"></script>
<script src="assets/common-files/js/masonry.pkgd.min.js"></script>
<script src="assets/common-files/js/modernizr.custom.js"></script>
<script src="assets/common-files/js/page-transitions.js"></script>
<script src="assets/common-files/js/easing.min.js"></script>
<script src="assets/common-files/js/jquery.svg.js"></script>
<script src="assets/common-files/js/jquery.svganim.js"></script>
<script src="assets/common-files/js/jquery.backgroundvideo.min.js"></script>
<script src="assets/common-files/js/froogaloop.min.js"></script>
<script src="assets/common-files/js/startup-kit.js"></script>
</div>
</body>
</html>