Learn R Programming

MoTBFs (version 2.0)

getMotbfDim: Extract Dimension of MoTBFs

Description

Get the dimension of "motbf" and "jointmotbf" densities.

Usage

getMotbfDim(P)

Value

Dimension of the function.

Arguments

P

An object of class "motbf" and subclass 'mop' or "jointmotbf".

See Also

univMoTBF and jointmotbf.fit

Examples

Run this code
## 1. EXAMPLE 
## Data
X <- rnorm(2000)

## Univariate function
f <- univMoTBF(X, POTENTIAL_TYPE = "MOP")
getMotbfDim(f)

## 2. EXAMPLE 
## Dataset with 2 variables
X <- data.frame(x = rnorm(100), y = rnorm(100))

## Joint function
dim <- c(2,3)
P <- jointmotbf.fit(X, dimensions = dim)

## Dimension of the joint function
getMotbfDim(P)

Run the code above in your browser using DataLab