View source: R/GetAllSatellites.R
| GetAllSatellites | R Documentation | 
Gets the information about all the satellites known in the Spectator Earth database, and possibly their current positions.
GetAllSatellites(positions = TRUE)
positions | 
 logical indicating if the current position should be included. Default: TRUE  | 
If positions is FALSE, a data frame with following attributes:
idinteger identifier
namecharacter satellite name
norad_idinteger satellite catalog number
openlogical whether the data produced by the satellite is freely accessible
platformcharacter platform name
sensor_namecharacter name of the sensor available on the satellite
sensor_swathinteger swath width of the sensor available on the satellite
sensor_typecharacter type of the sensor available on the satellite (SAR or Optical)
If positions is TRUE, object of class 'sf' with 'POINT' geometry type,
with the same attributes as above.
https://api.spectator.earth/#satellites
GetSatellite
if(interactive()){
 library(sf)
 # get all satellites withe their positions
 pos <- GetAllSatellites(positions = TRUE)
 # do some nice graphs
 library(maps)
 map("world", fill = TRUE, col = "lightgrey")
 # show open data satellites in green
 plot(st_geometry(subset(pos, open == TRUE)), add = TRUE, col = "green", pch = 15)
 # show others in red
 plot(st_geometry(subset(pos, open == FALSE)), add = TRUE, col = "red", pch = 16)
 # add labels
 xy <- st_coordinates(pos)
 # shift labels up to be able to read them
 xy[, 2] <- xy[, 2] + 2 
 text(xy, labels = pos$name, cex = 0.5)
 }
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.