powered by
Create a triangular membership function.
Creates a triangular membership function object.
triMF(mfName, x, mfParams)
String representing the name.
The range, should be a numerical vector such as 1:10
The input parameters, which should be a 4 number vector representing the left, mean, right and height.
$mfParams for the stored parameters.
$mfX for the stored range.
$mfName for the stored name.
$mfVals for the stored evaluated values.
Where is the assigned name of the membership function in the environment.
MyMembershipFunction <<- triMF("MyTri", 1:10, c(3,6,8,1))
Run the code above in your browser using DataLab