Skip to content

Commit c0dc70e

Browse files
committed
fix schema
1 parent c80aebb commit c0dc70e

19 files changed

Lines changed: 233 additions & 47 deletions

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "rmcp"
3-
version = "0.4.1"
3+
version = "0.4.2"
44
description = "Comprehensive Model Context Protocol server with 44 statistical analysis tools, flexible configuration, and HTTP transport"
55
authors = ["Gaurav Sood <gsood07@gmail.com>"]
66
license = "MIT"

rmcp/r_assets/scripts/descriptive/frequency_table.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,10 @@ result <- list(
5555
Missing_Values = ifelse(is.null(ft$n_missing), 0, ft$n_missing)
5656
)
5757
}))
58-
as.character(knitr::kable(
58+
paste(as.character(knitr::kable(
5959
freq_summary,
6060
format = "markdown", digits = 4
61-
))
61+
)), collapse = "\n")
6262
},
6363
error = function(e) {
6464
"Frequency tables created successfully"

rmcp/r_assets/scripts/descriptive/outlier_detection.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ result <- list(
5555
Total_Observations = length(values_clean),
5656
Outlier_Percentage = round(length(outliers) / length(values_clean) * 100, 2)
5757
)
58-
as.character(knitr::kable(
58+
paste(as.character(knitr::kable(
5959
outlier_df,
6060
format = "markdown", digits = 4
6161
))

rmcp/r_assets/scripts/descriptive/summary_stats.R

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -70,10 +70,10 @@ if (is.null(group_by)) {
7070
s <- stats_list[[var]]
7171
data.frame(variable = var, n = s$n, mean = s$mean, sd = s$sd, min = s$min, max = s$max)
7272
}))
73-
as.character(knitr::kable(
73+
paste(as.character(knitr::kable(
7474
stats_df,
7575
format = "markdown", digits = 4
76-
))
76+
)), collapse = "\n")
7777
},
7878
error = function(e) {
7979
"Summary statistics computed successfully"
@@ -108,10 +108,10 @@ if (is.null(group_by)) {
108108
{
109109
# Create summary table for grouped stats
110110
group_summary <- paste0("Grouped statistics by ", group_by, " (", length(groups), " groups)")
111-
as.character(knitr::kable(
111+
paste(as.character(knitr::kable(
112112
data.frame(Summary = group_summary),
113113
format = "markdown"
114-
))
114+
)), collapse = "\n")
115115
},
116116
error = function(e) {
117117
"Grouped summary statistics computed successfully"

rmcp/r_assets/scripts/econometrics/instrumental_variables.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ result <- list(
6767
{
6868
# Try to tidy the IV model
6969
tidy_model <- broom::tidy(iv_model)
70-
as.character(knitr::kable(
70+
paste(as.character(knitr::kable(
7171
tidy_model,
7272
format = "markdown", digits = 4
7373
))
@@ -80,7 +80,7 @@ result <- list(
8080
Observations = nobs(iv_model),
8181
Robust_SE = robust
8282
)
83-
as.character(knitr::kable(
83+
paste(as.character(knitr::kable(
8484
iv_summary,
8585
format = "markdown", digits = 4
8686
))

rmcp/r_assets/scripts/econometrics/panel_regression.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ result <- list(
6565
{
6666
# Try to tidy the panel model
6767
tidy_model <- broom::tidy(model)
68-
as.character(knitr::kable(
68+
paste(as.character(knitr::kable(
6969
tidy_model,
7070
format = "markdown", digits = 4
7171
))
@@ -78,7 +78,7 @@ result <- list(
7878
Time_Periods = pdim(model)$nT$T,
7979
R_Squared = round(summary(model)$r.squared[1], 4)
8080
)
81-
as.character(knitr::kable(
81+
paste(as.character(knitr::kable(
8282
panel_summary,
8383
format = "markdown", digits = 4
8484
))

rmcp/r_assets/scripts/econometrics/var_model.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ result <- list(
6060
AIC = round(AIC(var_model), 2),
6161
BIC = round(BIC(var_model), 2)
6262
)
63-
as.character(knitr::kable(
63+
paste(as.character(knitr::kable(
6464
var_summary_df,
6565
format = "markdown", digits = 4
6666
))

rmcp/r_assets/scripts/machine_learning/decision_tree.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ result <- list(
6969
{
7070
# Try to tidy the tree model
7171
tidy_tree <- broom::tidy(tree_model)
72-
as.character(knitr::kable(
72+
paste(as.character(knitr::kable(
7373
tidy_tree,
7474
format = "markdown", digits = 4
7575
))
@@ -82,7 +82,7 @@ result <- list(
8282
Complexity = round(tree_model$cptable[nrow(tree_model$cptable), "CP"], 6),
8383
Observations = nrow(data)
8484
)
85-
as.character(knitr::kable(
85+
paste(as.character(knitr::kable(
8686
tree_summary,
8787
format = "markdown", digits = 4
8888
))

rmcp/r_assets/scripts/machine_learning/kmeans_clustering.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ result <- list(
6767
Variance_Explained = round(between_ss / total_ss * 100, 2),
6868
Silhouette_Score = round(silhouette_score, 3)
6969
)
70-
as.character(knitr::kable(
70+
paste(as.character(knitr::kable(
7171
cluster_summary,
7272
format = "markdown", digits = 4
7373
))

rmcp/r_assets/scripts/machine_learning/random_forest.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ result <- list(
113113
OOB_Error = if (is.null(oob_error_val)) NA else round(oob_error_val, 4),
114114
Observations = nrow(data)
115115
)
116-
as.character(knitr::kable(
116+
paste(as.character(knitr::kable(
117117
rf_summary,
118118
format = "markdown", digits = 4
119119
))

0 commit comments

Comments
 (0)