c***z 发帖数: 6348 | 1 ## build data frame
work <- c(12, 14, 4, 16, 12, 20, 25, 8, 24, 28, 4, 15)
edu <- c(6,3,8,8,4,4,1,3,12,9,11,4)
income <- c(34.7, 17.9, 22.7, 63.1, 33.0, 41.4, 20.7, 14.6, 97.3, 72.1, 49.1
, 52.0)
studay.df <- data.frame(cbind(work, edu, income))
## linear model
model_3 <- lm(income ~ ., data = studay.df) # OLS
summary_table <- data.frame(summary(model_3)$coefficients)
colnames(summary_table) <- c("coef", "std.error", "t_value", "p_value")
summary_table$regressor <- row.names(summary_table)
s... 阅读全帖 |
|
w***n 发帖数: 150 | 2 From: International Journal of Hydrology Science and Technology
Title: Comparison between support vector machine and nonlinear regression
for predicting saturated hydraulic conductivity
Required by Mar 19, 2018.
Abstract
Saturated hydraulic conductivity (Ks) is playing an important role in
irrigation, and drainage. The aim of the study was to validate Pedotransfer
Functions (PTFs) using non-linear regression (NLR) and support vector
machine (SVM) for estimation Ks. Moreover, selecting the best p... 阅读全帖 |
|
c***z 发帖数: 6348 | 3 就是我们公司有一个model,预测网上shopping cart里面会有什么东西
我改进的model比老model RMSE要低
但是老model把cart size normalize to 1,虽然没什么依据
于是让我把新model也normalize,结果RMSE显示老model好
虽然我解释说因为normalization distorted data at local level所以RMSE不再是有
效的指示,并且用了US coast line 和 加州 coast line谁更长做例子,但是自己感觉
不是很hit the point
大家有什么idea么?谢谢啦 |
|
A*******s 发帖数: 3942 | 4 这个问题应该是怎么把square error loss function和model实际目的联系起来。
按照OP的做法,直接将# of items作target variable然后minimize RMSE,其实更合理
的假设是target variable服从的是Poisson,或者至少应该假设是variance increases
with mean,那么optimize RMSE的后果是# of items比较大的observations会dominate
model。
按照old model的做法,把percentage作为target variable,这样optimize RMSE的后
果就刚好相反了,# of items比较小的observations会dominate model。
哪个更合理,就看business的需要了。 |
|
c***z 发帖数: 6348 | 5 【 以下文字转载自 Statistics 讨论区 】
发信人: chaoz (面朝大海,吃碗凉皮), 信区: Statistics
标 题: 工作中遇到的一个现象,问问大家怎么解释
发信站: BBS 未名空间站 (Sat Mar 22 17:38:16 2014, 美东)
就是我们公司有一个model,预测网上shopping cart里面会有什么东西
我改进的model比老model RMSE要低
但是老model把cart size normalize to 1,虽然没什么依据
于是让我把新model也normalize,结果RMSE显示老model好
虽然我解释说因为normalization distorted data at local level所以RMSE不再是有
效的指示,并且用了US coast line 和 加州 coast line谁更长做例子,但是自己感觉
不是很hit the point
大家有什么idea么?谢谢啦 |
|
c***z 发帖数: 6348 | 6 Hi all,
Does anyone have experience in bias correction? I am working on a project
and the initial result was bad. I would really really appreciate any help!
Here is the details:
Business objective: Correct for panel bias in terms of demographic breakdown
, to obtain an accurate multiplier, in order to calculate site traffic,
sales, etc
Input data:
1. Site visits by people (own data, company Q);
2. Third party (C) 2000 site gender decomposition;
3. Third party personal gender labels (two... 阅读全帖 |
|
v*******e 发帖数: 11604 | 7 normalize之后当然RMSE就变了,residue分布已经不是normal分布了(其实原来就不是
normal分布,原来是poisson分布吧?),既然不是normal分布,RMSE就不能做为一个分
辨好坏的指标。 |
|
c***z 发帖数: 6348 | 8 Thank you all so much for the inputs! As always, you guys are most helpful!
For some more context, we are trying to predict conversion based on page
view. The old model says everything will be bought, and then normalize so
that the cart size is one.
The new tree model tries to predict individual conversion rate. I played
with the tree model a little so that it outperforms the old model even after
normalizing.
I think it is the weighting (normalization) that distorted the data and RMSE.
I agree t... 阅读全帖 |
|
c***z 发帖数: 6348 | 9 Just did a second round and it was way off.
Here is what I did. Any input is extremely welcome!
Business objective: Correct for panel bias in terms of demographic breakdown
, to obtain an accurate multiplier, in order to calculate site traffic,
sales, etc
Input data:
1. Site visits by people (own data, company Q);
2. Third party (C) 2000 site gender decomposition;
3. Third party personal gender labels (two companies, E and L);
Technical logic:
1. Assign a score to sites based on thei... 阅读全帖 |
|
l******n 发帖数: 9344 | 10 C-stat and RMSE correspond to very different problems...
In general, look at the top 10 most important factors in your old model then
compare the effects with the new data. If they are not far away, you can
proceed to check more or just keep one variable in the model and compare the
C-stat or RMSE. This is more than checking model works or not, because it
also considers the contribution of each variable at least important ones.
high, |
|
c***z 发帖数: 6348 | 11 Thank you all so much for the inputs! As always, you guys are most helpful!
For some more context, we are trying to predict conversion based on page
view. The old model says everything will be bought, and then normalize so
that the cart size is one.
The new tree model tries to predict individual conversion rate. I played
with the tree model a little so that it outperforms the old model even after
normalizing.
I think it is the weighting (normalization) that distorted the data and RMSE.
I agree t... 阅读全帖 |
|
d*****s 发帖数: 5610 | 12 说句实话,你这种回帖,做统计的人一般不会回你。明显不懂.
预测成功标准,不是在一件事上预测,而是不断预测,然后看一些评估标准,比如,
RMSE, root mean squared error, 或者Brier score. 这是方法论,而不是意气用事。 |
|
s********s 发帖数: 3945 | 13 For the function
[b,bint,r,rint,stats] = regress(y,X)
where stats = [r2 F prob s2];
My question is what the definition of s2 is. In matlab web, "s2" is defined
as the square of the root mean square error (RMSE) value. So it should be
the same as MSE (mean square error), right?
Thanks for your correction. |
|
m******n 发帖数: 453 | 14 ML还是DL,都不能给出optimal results
给出一个价格模型,无论rmse有多小,可是老板需要知道的是,究竟应该定价多少啊?
考虑到满足各种constraints
最后,商业中应用的还是离不开传统的优化线性规划
对不对? |
|
C*******M 发帖数: 153 | 15 The following table shows the number of actual and expected deaths in the
last ten years:
Actual: 12 15 18 21 24 27 28 25 23 18
Expected: 20 22 24 26 27 26 24 22 19 16
I am wondering if I can use Theil's U2 inequality for accuracy the above
expected value. The formula is attached and I am confused about the formula.
There are several accuracy measurements: Mean Absolute Deviation (MAD), Root
Mean Square Error (RMSE), Mean Absolute Percentage Error (MAPE), Theil's
Measure of Inequality (U2), Co |
|
S******y 发帖数: 1123 | 16 I have split my data into training(70%) and hold-out (30%) data.
I fit a linear model with k parameters on training data, and obtained
model M1.
Then I used the parameter estimates from training data to compute
predicted values for hold-out data (i.e. score the hold-out data).
Aside from MSE or RMSE (Root Mean Square Error), can I use other model
diagnostic metrics to evaluate model fit on hold-out data? For example,
does it make sense to compute AIC value for my model M1 on hold-out data?
(we |
|
D******n 发帖数: 2836 | 17 correlation coefficients?
RMSE? |
|
|
t********m 发帖数: 939 | 19 多谢回复,我也觉得看起来差不多,但是做了transformation之后好像是要好一点,
RMSE也小一些,就是不知道好这么一点值不值得啊。 |
|
|
c***z 发帖数: 6348 | 21 For continuous Y, we use RMSE,
for binary Y, we use ROC, or the confusion matrix |
|
c***z 发帖数: 6348 | 22 1. I asked a similar question on this board; try K-S test for continuous
random, permutation test for discrete random
2. R^2, or just use RMSE to see if prediction is better; for prediction, it
doesn't matter, for inference, yes VIF
just my 2 cents |
|
A*******s 发帖数: 3942 | 23 没看明白
“shopping cart里面会有什么东西”这个算怎样的random variable?multiclass?
如果是multiclass的又怎么用RMSE来衡量? |
|
c***z 发帖数: 6348 | 24 yeah, that was my intuition, but I couldn't nail it exactly how the impact
happened
error metric was RMSE
I am considering confusion matrix, but the conversion is kind of sparse
events, so maybe something more sophisticated is needed |
|
c***z 发帖数: 6348 | 25 Sure, by still work I meant work well, precisely, the C-stat should be high,
or the RMSE should be low. |
|
M*Q 发帖数: 54 | 26 RMSE算的是shopping cart里东西的个数?
所以还要先predict什么会出现在shopping cart里面吗?
★ 发自iPhone App: ChineseWeb 8.6 |
|
c***z 发帖数: 6348 | 27 Exactly. I have propose to start from the business questions.
And this is the reply from boss:
"I am not clear what kind of answers from 'business' you are looking for. It
has always been the same: Ability to differentiate good location quality
traffic from bad location quality traffic."
Still, no idea about what "good traffic" means, just a bunch of good/bad
traffic samples, need to generalize to a definition.
So we don't have a definition for goodness, nor a definition for metric, nor
an idea ... 阅读全帖 |
|
c***z 发帖数: 6348 | 28 Exactly. I have propose to start from the business questions.
And this is the reply from boss:
"I am not clear what kind of answers from 'business' you are looking for. It
has always been the same: Ability to differentiate good location quality
traffic from bad location quality traffic."
Still, no idea about what "good traffic" means, just a bunch of good/bad
traffic samples, need to generalize to a definition.
So we don't have a definition for goodness, nor a definition for metric, nor
an idea ... 阅读全帖 |
|
s*****n 发帖数: 134 | 29 没系统学习过时间序列。随便说说想法
1. 用窗口函数对原始序列做预处理,过滤掉高频成分: https://en.wikipedia.org/
wiki/Window_function
2. 干脆预设几个固定的频率,然后对结果(IFFT)根据RMSE做筛选? |
|
g****u 发帖数: 25 | 30 骑驴找马今天面了一个感觉牛逼哄哄的startup, 已挂,满满的挫败感。最大的感受是
平时做项目的时候machine learning的算法都是抓来用用,那个好用用哪个,但对算法
的理解都很肤浅,没有深入思考过。大牛们看看下面几个问题怎么回答才好?
1)第一个问题是我有一个项目用mape来evaluate模型,面试官问我为什么不能用rmse
,我说mape是客户要求的,所以我就没多想,我实在不好意思讲我当时瞎扯了点啥,
太打脸了
2)面试官问我favorite的算法是什么,我说没有,平时logistic regression和random
forest用的比较多,然后面试官就问我什么时候用lg什么时候用rf。虽然我理论上知
道一点各自的特点比如lg对outlier比较敏感,模型interpretability比较高, rf是non
-parametric的所以对outlier不敏感,不用担心colinearity的问题之类的,但用到具
体问题的时候,我就说不上来了,因为其实我是抓来都用用,如果两个算法
performance差的比较大,我就直接用好的那个。我临时就凭感觉说如果featu... 阅读全帖 |
|