Run_MCMC {BayesianFitForecast}R Documentation

Run MCMC Analysis with Specified Option File

Description

This function runs an MCMC analysis based on the specified option file, sourcing auxiliary scripts, and executing the analysis.

Usage

Run_MCMC(option_file, excel_file = NULL, output_path = NULL)

Arguments

option_file

The name of the option file (e.g., "option1.R") located in the current working directory.

excel_file

The path to the Excel file containing the data.

output_path

Directory where the output will be saved. If NULL, uses a temporary directory.

Value

None. The function executes and saves results directly.

Examples

# Get path to the example option file included with package
option_file <- system.file("extdata", "option.R", 
                          package = "BayesianFitForecast")
                          
# Specify the path to the Excel file you want to analyze
excel_file <- system.file("extdata", "SanFrancisco.xlsx", 
                          package = "BayesianFitForecast")  # Modify this path accordingly
                          
# Run the MCMC analysis

Run_MCMC(option_file = option_file, excel_file = excel_file, output_path = NULL)


[Package BayesianFitForecast version 1.0.0 Index]