Learn R Programming

RegKink (version 0.1.0)

pos.part: positive part of a variable

Description

This is a function computing the positive part of a variable.

Usage

pos.part(x)

Arguments

x

A vector of response.

Value

ps

The positive part of a variable.

Examples

Run this code
# NOT RUN {
pt1 <- proc.time()
##Simulated data
set.seed(12345)
n=200
x = rnorm(n)
obj <- pos.part(x)

proc.time() - pt1
# }

Run the code above in your browser using DataLab