Learn R Programming

npdsim (version 1.0.0)

shape_sim: Generate the shape of demand

Description

Generate the shape of demand for new products by specifying their life cycle shape and the length of their life cycle

Usage

shape_sim(periods_number, shape_number, shape_type = "random")

Value

A numeric dateframe of three columns: time, shape and assigned_shape

Arguments

periods_number

Number of time periods of the products life cycle

shape_number

Number of generic shapes

shape_type

Type of shape to generate. It can take the values: "triangle", "trapezoid", "bass", "random" and "intro & growth". The type "random" picks one of the types "triangle", "trapezoid", "bass" randomly for each product. The type "intro & growth" is used for the shapes of the introduction and growth phases.

Examples

Run this code
shape_sim(periods_number=20, shape_number=5)
shape_sim(periods_number=20, shape_number=5,shape_type="trapezoid")

Run the code above in your browser using DataLab