andremonaco / cheapml Goto Github PK
View Code? Open in Web Editor NEWMachine Learning algorithms coded from scratch
License: MIT License
Machine Learning algorithms coded from scratch
License: MIT License
Thanks for sharing your code (reg_tree.R), this helped me save some time. If I understand your code correctly, I think below line 69 you may want to insert the following line:
y <- this_data[, as.character(formula)[2]]
Otherwise I think the sse is not calculated correctly.
Thanks.
Hi Andre,
Thanks for putting up this code. I an have a few problems and I thought I would check with you before looking further into them
Xy(task = "regression")
recipe <- Xy(task = "regression" ) %>%
add_linear(p = 2, family = xy_normal())
simulate(recipe)
I have not figured it out yet. I just used an older version of R with an older Xy
2) There seems to be a problem or a change with raply. Here is a small snippet showing what happens.
f<-function(){
list(runif(10), data.frame(matrix(0,2,2)))
}
temp <- plyr::raply(2, f() )
> temp
1 2
[1,] Numeric,10 List,2
[2,] Numeric,10 List,2
This can we fixed or at least worked around by changing you code to
trees<-lapply (c(1:n_trees), f<-function(x){sprout_tree(formula = formula, feature_frac = feature_frac, data = data )})
source("../algorithms/reg_rf.R")
mod3 <- reg_rf(formula = eq, data = model_df,n_trees=10,feature_frac=0.63)
plot(mod3$fit , model_df$y)
cor(mod3$fit, model_df$y) #0.01
I think this is because the fits coming out of sprout_tree are for the boostrapped data set and not the original data set.
I can see a fix for this but I thought I woudl check with you first in case I was missing something.
Bye
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.