This API produces efficient portfolios (portfolios that lie on the efficient frontier) based on daily funds' prices inputted by the user, and groups these portfolio into different clusters by hierarchical clustering. This API then calculates the Maximum, Median and Minimum Returns and Risks (standard deviations of returns) of each cluster. These clusters can also be seen as Model Portfolios for different risk profiles the user wish to create for their clients. Following are the adjustable constraints on the efficient portfolios generated:
-
Maximum and minimum weight on each fund in the portfolio
-
Computing speed - the lower the computing speed, the higher the number of efficient portfolios produced (higher accuracy of information in clusters)
-
Classification - to incorporate Core-Satellite Investing by classifying funds into “UC“ (Ultra Core), “C“ (Core), “S1“ (Satellite 1) or “S2“ (Satellite 2). Higher weights will be allocated to “UC“ funds, followed by “C“, “S1“ and “S2“.
-
Risk bucket - to classify funds as either “Safe“ or “Risky“. Weights allocated to “Risky“ funds are lower than weights on “Safe“ funds
User can also override expected returns and expected variances based on their company’s in-house estimation while using this API.
Request Body
Name | Datatype | Description | Mandatory | Sample values | List of possible values | No. of decimal places | Notes |
---|---|---|---|---|---|---|---|
nClusters | Integer | Number of risk profiles or number of clusters | Y | 5 | >= 1,<=10 | 0 | |
minWeight | Number | Minimum weight on each fund | Y | 0 | >=0, <=1 | 4 | |
maxWeight | Number | Maximum weight on each fund | Y | 1 | >=0, <=1 | 4 | maxWeight > minWeight |
computingSpeed | Integer | Determines the number of iterations, 1 is the most intensive. | Y | 5 | >=1, <=10 | 0 | Use lower computing speed to generate higher accuracy (more efficient portfolios) of efficient plot. |
priceRecords | Array | Record of daily funds' prices | Y | ||||
divAdjClose | Float | Daily dividend adjusted prices of funds | Y | 37.06 | 2 | ||
symbol | String | Symbols of funds | Y | “QQQ” | NA | ||
date | String | Date of price data | Y | "2008-08-22" | NA | ||
productDictionary | Array of Dictionaries | Contains additional constraints on weights of funds and information to be overridden. | Y when either “override“, “useRiskBuckets“, “useClassifications“ is true | ||||
Classification | String | Classification of the fund in core-satellite investing. | Y when “useClassifications“: true | "UC" | “UC“, “C“, “S1“, “S2“ | NA | Higher weights are allocated to “UC“ (ultra-core) funds, followed by “C“ (core), “S1“ (satellite 1) and “S2“ (satellite 2) funds. |
riskBucket | String | Classification of the fund’s riskiness. | Y when “useRiskBuckets“: true | "Safe" | “Safe“, “Risky“ | NA | Weights of “Risky“ funds are ensured to be lower than weights of “Safe“ funds |
expectedReturn | Float | Expected returns of the fund to be used instead of calculating based on “priceRecords” | Y when “override“: true | 0.01 | >=0, <=1 | not limited | |
expectedStdDev | Float | Expected variances of the fund to be used instead of calculating based on “priceRecords” | Y when “override“: true | 0.01 | >=0, <=1 | not limited | |
override | Boolean | To use expectedReturn and expectedStdDev of funds in “productDictionary“ rather than calculate from “priceRecords” | Y | false | true, false | NA | |
useRiskBuckets | Boolean | To add constraints on weights of funds based on funds' riskiness | Y | false | true, false | NA | |
useClassification | Boolean | To add constraints on weights of funds based their classifications in core-satellite investing | Y | false | true, false | NA |
Response Body
Name | Datatype | Description | Sample value | No. of decimals | Notes |
---|---|---|---|---|---|
clusteredEfficientFrontier | Array of dictionaries | Contains annualized returns and standard deviations pair of efficient portfolios in each cluster to plot the clustered efficient frontier plot | |||
return | Float | Annualized returns for each efficient portfolio | 0.0294 | 4 | |
stdDev | Float | Annualized standard deviations for each efficient portfolio | 0.0261 | 4 | |
clusterLabel | Integer | The cluster that the efficient portfolio belongs to | 1 | 0 | |
clusterSummary | Array of dictionaries | ||||
clusterLabel | Integer | Efficient portfolios clusters | 1 | 0 | |
maxReturn | Float | Maximum annualized return for the cluster | 0.0473 | 4 | |
maxStdDev | Float | Maximum annualized standard deviation of returns for the cluster | 0.0476 | 4 | |
medianReturn | Float | Median annualized return for the cluster | 0.0383 | 4 | |
medianStdDev | Float | Median annualized standard deviation of returns for the cluster | 0.0343 | 4 | |
minReturn | Float | Minimum annualized return for the cluster | 0.0473 | 4 | |
minStdDev | Float | Minimum annualized standard deviation of returns for the cluster | 0.0473 | 4 |