best_dist | R Documentation |
This function takes in a data frame of AIC values for different distributions and a vector of distribution names, and returns a data frame with the best distribution for each row based on the minimum AIC value. #' You can also write the distribution as "norm" or "cauchy" provided they follow the order in the data frame.
best_dist(aic_df, dist_names)
aic_df |
A data frame containing AIC values for different distributions |
dist_names |
A vector of distribution names corresponding to the AIC values |
A data frame with the best distribution for each row based on the minimum AIC value
This function takes the data frame obtained from fit_multiple_dist
function
data <- asset_loader(system.file("extdata", package = "StockDistFit"), c("AAPL", "TSLA"), "Close")
df = fit_multiple_dist(c("norm_fit", "cauchy_fit"), data)
best_dist(df, c("norm_fit", "cauchy_fit"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.