Slides are composed of analyses, which are effectively CrunchCubes with some
additional metadata. You can get and set a slide's Analysis Catalog with the
analyses method, and access an individual analysis with analysis.
filter(x, ...)filter(x) <- value
# S4 method for CrunchDeck,ANY
filter(x) <- value
analyses(x)
analysis(x)
analysis(x) <- value
query(x) <- value
cube(x)
cubes(x)
# S4 method for CrunchSlide
analyses(x)
# S4 method for CrunchSlide
analysis(x)
# S4 method for CrunchSlide,formula
analysis(x) <- value
# S4 method for CrunchSlide,Analysis
analysis(x) <- value
# S4 method for CrunchSlide,list
analysis(x) <- value
# S4 method for CrunchSlide
filter(x, ...)
# S4 method for CrunchSlide,ANY
filter(x) <- value
# S4 method for CrunchSlide,ANY
query(x) <- value
# S4 method for CrunchSlide
cubes(x)
# S4 method for CrunchSlide
cube(x)
# S4 method for AnalysisCatalog
cubes(x)
# S4 method for Analysis,formula
query(x) <- value
formulaToSlideQuery(query, dataset)
# S4 method for Analysis
cube(x)
# S4 method for Analysis
filter(x, ...)
# S4 method for ANY
filter(x, ...)
# S4 method for CrunchSlide,ANY
filter(x) <- value
# S4 method for Analysis,CrunchLogicalExpr
filter(x) <- value
# S4 method for Analysis,CrunchFilter
filter(x) <- value
# S4 method for Analysis,`NULL`
filter(x) <- value
slideQueryEnv(weight, filter)
a CrunchSlide, AnalysisCatalog, or Analysis
ignored
for the setter, a query
For formulaToSlideQuery(), a formula that specifies the query, as in
newSlide()
For formulaToSlideQuery(), a CrunchDataset that the variables in
query refer to.
For slideQueryEnv() a crunch variable to use as a weight or NULL
to indicate no weight should be used.
for slideQueryEnv(), a CrunchFilter or CrunchExpression to filter
the slide.
an AnalysisCatalog, Analysis, Cube, or Filter
You can get the CrunchCube from a slide or analysis with the cube method and
from a CrunchDeck with cubes. Analyses can be changed by assigning a formula
into the query function.
Advanced users of the API can assign a list to analysis<- to specify settings
on the analyses that are not otherwise available in rcrunch. The helpers
formulaToSlideQuery() and slideQueryEnv() help you create objects for the
query and query_environment.
# NOT RUN {
analysis(slide)
cube(slide)
cubes(deck)
query(slide) <- ~ cyl + wt
filter(slide)
filter(slide) <- NULL # to remove a filter
filter(slide) <- filters(ds)[["My filter"]]
# }
Run the code above in your browser using DataLab