# Load required packages
library(dplyr)
library(openxlsx)
# Generate sample data with custom column names
set.seed(123)
sample_data <- data.frame(
Time = rep(c("Aug", "Sep"), each = 100),
Size = runif(200, min = 5, max = 20)
)
# Create frequency table with automatic bin width and default date config
result <- FreqTM(data = sample_data, output_file = tempfile(fileext = ".xlsx"))
# Create frequency table with custom bin width and specific date
result <- FreqTM(data = sample_data, bin_width = 2,
date_config = list(day = 15, year = 2026),
output_file = tempfile(fileext = ".xlsx"))
Run the code above in your browser using DataLab