Learn R Programming

spocc (version 0.2.4)

spocc_objects: spocc objects and their print, plot, and summary methods

Description

spocc objects and their print, plot, and summary methods

Usage

## S3 method for class 'occdat':
print(x, ...)

## S3 method for class 'occdatind': print(x, ..., n = 10)

## S3 method for class 'occdat': summary(object, ...)

## S3 method for class 'occdatind': summary(object, ...)

## S3 method for class 'occdat': plot(x, ...)

## S3 method for class 'occnames': print(x, ...)

Arguments

x
Input, of class occdatind
...
Further args to print, plot or summary methods
n
Number of rows to show. If NULL, the default, will print all rows if less than option dplyr.print_max. Otherwise, will print dplyr.print_min
object
Input to summary methods

Examples

Run this code
# occdat object
res <- occ(query = 'Accipiter striatus', from = 'gbif')
res
print(res)
is(res)

# occdatind object
res$gbif
print(res$gbif)
is(res$gbif)

# print summary of occdat object
summary(res)

# print summary of occdatind object
summary(res$gbif)

# plot an occdat object
spnames <- c('Accipiter striatus', 'Setophaga caerulescens', 'Spinus tristis')
out <- occ(query=spnames, from='gbif', gbifopts=list(hasCoordinate=TRUE))
plot(out, cex=1, pch=10)

Run the code above in your browser using DataLab