Skip to contents

Plot signal strength vs time for specified tag, faceted by site (ordered by latitude) and coloured by antenna

Usage

plotTagSig(data, motusTagID)

Arguments

data

a selected table from .motus data, eg. "alltagsGPS", or a data.frame of detection data including at a minimum variables for motusTagID, sig, ts, antBearing, recvDeployLat, fullID, recvDeployName, gpsLat, gpsLon

motusTagID

a numeric motusTagID to display in plot

Examples

# Download sample project 176 to .motus database (username/password are "motus.sample")
if (FALSE) sql_motus <- tagme(176, new = TRUE)

# Or use example data base in memory
sql_motus <- tagmeSample()

# convert sql file "sql_motus" to a tbl called "tbl_alltags"
library(dplyr)
tbl_alltags <- tbl(sql_motus, "alltagsGPS") 

# convert the tbl "tbl_alltags" to a data.frame called "df_alltags"
df_alltags <- tbl_alltags %>% 
  collect() %>% 
  as.data.frame()

# Plot signal strength of a specified tag using dataframe df_alltags
plotTagSig(df_alltags, motusTagID = 16047)


# Plot signal strength of a specified tag using tbl file tbl_alltags
plotTagSig(tbl_alltags, motusTagID = 16035)