Module extendr_api::prelude

source ·
Expand description

§Common exports for extendr-api.

This allows us to be more selective about exports and avoid users using deprecated features.

Re-exports§

Modules§

Macros§

  • Execute R code by parsing and evaluating tokens.
  • Execute R code by parsing and evaluating tokens but without expanding parameters.
  • Create an Array with one, two or three dimensions.
  • Array zip macro: lock step function application across several arrays and producers.
  • Call a function or primitive defined by a text expression with arbitrary parameters. This currently works by parsing and evaluating the string in R, but will probably acquire some shortcuts for simple expessions, for example by caching symbols and constant values.
  • Concatenate arrays along the given axis.
  • Create a dataframe.
  • Define a module and export symbols to R Example:
  • Create a factor.
  • Evaluate the provided expression for both Either::Left and Either::Right.
  • Get a global variable.
  • A macro for constructing R langage objects.
  • Create a List R object from a list of name-value pairs.
  • Create a Pairlist R object from a list of name-value pairs.
  • Convert a rust expression to an R object.
  • Print via the R error stream.
  • Print with a newline via the R output stream.
  • Print via the R output stream.
  • Print with a newline via the R output stream.
  • Slice argument constructor.
  • Stack arrays along the new axis.
  • stack_new_axisDeprecated
    Stack arrays along the new axis.
  • The sym! macro install symbols. You should cache your symbols in variables as generating them is costly.
  • Macro for running tests.
  • Macro for unwrapping the left side of an Either, which fails early with the opposite side. Can only be used in functions that return Either because of the early return of Right that it provides.
  • Dual to try_left!, see its documentation for more information.
  • Get a local variable from the calling function or a global variable if no such variable exists.

Structs§

  • An n-dimensional array.
  • An axis index.
  • Description of the axis, its length and its stride.
  • Dimension description.
  • Iterator that maps left or right iterators to corresponding Either-wrapped items.
  • Dynamic dimension or index type.
  • A transparent wrapper of Cell<T> which is identical in every way, except it will implement arithmetic operators as well.
  • Token to represent a new axis in a slice description.
  • ArcArray’s representation.
  • Array’s representation.
  • Array pointer’s representation.
  • A contiguous array shape of n dimensions.
  • An error related to array shape or layout.
  • A slice (range with step size).
  • Represents all of the necessary information to perform a slice.
  • An array shape of n dimensions in c-order, f-order or custom strides.
  • Array view’s representation.
  • Lock step function application across several arrays or other producers.

Enums§

  • CowArray’s representation.
  • The enum Either with variants Left and Right is a general purpose sum type with two cases.
  • Error code for an error related to array shape or layout.
  • Value controlling the execution of .fold_while on Zip.
  • Array order
  • A slice (range with step), an index, or a new axis token.

Traits§

  • Argument conversion into an array view
  • A producer element that can be assigned to once
  • Array representation trait.
  • Array representation trait.
  • Array representation trait.
  • Array representation trait.
  • Adds the two dimensions at compile time.
  • Array shape and index trait.
  • Fixed-size array used for array initialization
  • Extra indexing methods for array views
  • Argument conversion a dimension.
  • Argument conversion into a producer.
  • Elements that support linear algebra operations.
  • Slicing information describing multiple mutable, disjoint slices.
  • Floating-point element types f32 and f64.
  • Tuple or fixed size arrays that can be used to index an array.
  • A producer of an n-dimensional set of elements; for example an array view, mutable array view or an iterator that yields chunks.
  • Array representation trait.
  • Array representation trait.
  • Array representation trait.
  • Array representation trait.
  • Array shape with a next smaller dimension.
  • Elements that can be used as direct operands in arithmetic with arrays.
  • Array shape argument with optional order parameter
  • A trait for Shape and D where D: Dimension that allows customizing the memory layout (strides) of an array shape.
  • A type that can slice an array of dimension D.
  • Simple and safe type conversions that may fail in a controlled way under some circumstances. It is the reciprocal of TryInto.
  • An attempted conversion that consumes self, which may or may not be expensive.

Functions§

  • Create a new dimension value.
  • Create a zero-dimensional index
  • Create a one-dimensional index
  • Create a two-dimensional index
  • Create a three-dimensional index
  • Create a four-dimensional index
  • Create a five-dimensional index
  • Create a six-dimensional index
  • Create a dynamic-dimensional index
  • Create a zero-dimensional array with the element x.
  • Create a one-dimensional array with elements from xs.
  • Create a two-dimensional array with elements from xs.
  • Create a three-dimensional array with elements from xs.
  • Create a zero-dimensional array view borrowing x.
  • Create a one-dimensional array view with elements borrowing xs.
  • Create a two-dimensional array view with elements borrowing xs.
  • Create a one-dimensional read-write array view with elements borrowing xs.
  • Create a two-dimensional read-write array view with elements borrowing xs.
  • Concatenate arrays along the given axis.
  • Create an iterable of the array shape shape.
  • Return an iterable of the indices of the passed-in array.
  • Create a one-dimensional array with elements from xs.
  • Create a two-dimensional array with elements from xs.
  • Create a three-dimensional array with elements from xs.
  • Stack arrays along the new axis.
  • stack_new_axisDeprecated
    Stack arrays along the new axis.

Type Aliases§

Attribute Macros§

Derive Macros§

  • Enable the construction of dataframes from arrays of structures.