nVariables: Number of Variables in a Joint Function

View source: R/joint.R

nVariablesR Documentation

Number of Variables in a Joint Function

Description

Compute the number of variables which are in a jointmotbf object.

Usage

nVariables(P)

Arguments

P

An "motbf" object or a "jointmotbf" object.

Value

A "character" vector with the names of the variables in the function.

Examples


# 1. EXAMPLE
## Generate a dataset
data <- data.frame(X1 = rnorm(100), X2 = rnorm(100))

## Joint function
dim <-c(3,2)
param <- parametersJointMoTBF(data, dimensions = dim)
P <- jointMoTBF(param)
P

## Variables
nVariables(P)

##############################################################################
## MORE EXAMPLES #############################################################
##############################################################################

## Generate a dataset
data <- data.frame(X1 = rnorm(100), X2 = rnorm(100), X3 = rnorm(100))

## Joint function
dim <- c(2,1,3)
param <- parametersJointMoTBF(data, dimensions = dim)
P <- jointMoTBF(param)

## Variables
nVariables(P)


MoTBFs documentation built on April 18, 2022, 5:06 p.m.

Related to nVariables in MoTBFs...