Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

merge

merge or split stars object


Description

merge attributes into a dimension, or split a dimension over attributes

Usage

## S3 method for class 'stars'
split(x, f = length(dim(x)), drop = TRUE, ...)

## S3 method for class 'stars'
merge(x, y, ..., name = "attributes")

Arguments

x

object of class stars

f

the name or index of the dimension to split; by default the last dimension

drop

ignored

...

if defined, the first unnamed argument is used for dimension values, if not defined, attribute names are used for dimension values

y

needs to be missing

name

name for the new dimension

Details

split.stars works on the first attribute, and will give an error when more than one attribute is present

Value

merge merges attributes of a stars object into a new dimension; split splits a dimension over attributes


stars

Spatiotemporal Arrays, Raster and Vector Data Cubes

v0.5-2
Apache License
Authors
Edzer Pebesma [aut, cre] (<https://orcid.org/0000-0001-8049-7069>), Michael Sumner [ctb] (<https://orcid.org/0000-0002-2471-7511>), Etienne Racine [ctb], Adriano Fantini [ctb], David Blodgett [ctb]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.