由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Statistics版 - logistic regression结果释疑,解读
相关主题
请问关于LOGISTIC REGRESSION FORWARD VS BACKWARD找工作总结 [下]
问个logistic regression的问题。one question about variable selection in SAS
报面筋求实习合租 (转载)请教backward, forward and stepwise在做variable selection时的区别
logistic regression issue用LASSO选变量后重新fit regression有什么弊端?
有什么variable selection的方法可以用在Logistic regression上?电话面试完了,肯定没戏,大家帮我看看题目,就算学习吧
紧急求助,问到MULTIPLE REGRESSION的题请问:想fit gamma 并同时用lasso的方法做variable selection
抓狂!为啥选出来的predictor都这么差关于lasso的variable selection问题
有80个候选Predictors,怎么从中选<10个logistic, overfit了怎么办?
相关话题的讨论汇总
话题: variable话题: regression话题: logistic话题: sas话题: best
进入Statistics版参与讨论
1 (共1页)
s*******o
发帖数: 392
1
做logistic regression回国前准备:
1. independent variable:国外金融论坛有关交易词汇的统计:比如“trader,
indicator, long, short, market, crazy”等有160个词汇的每日出现的相对频率,经
过normalization,比如trader 的出现的次数除以当天总的帖子数目。
2. 预测对象:binary variable: 明日的volatility是否是top 15%, 比如大于60%这
个值。 这样1 为大于,0 为小于。
用sas的logistic regression做回国,方法backward,因为不可能160个词汇都有预测
能力,所以希望削减variable数量。
模型stay的标准0.05,
结果如下:
问题,最后sas给我选出来的可预测的词汇有52个之多,如上图,df比较高,可是其结
论是这样的模型fit最好,这里是否有overfit的隐私存在呢,或者其他的一些明显的缺
点呢?谢谢大家了
n*****n
发帖数: 3123
2
一时错觉以为到了海归版

【在 s*******o 的大作中提到】
: 做logistic regression回国前准备:
: 1. independent variable:国外金融论坛有关交易词汇的统计:比如“trader,
: indicator, long, short, market, crazy”等有160个词汇的每日出现的相对频率,经
: 过normalization,比如trader 的出现的次数除以当天总的帖子数目。
: 2. 预测对象:binary variable: 明日的volatility是否是top 15%, 比如大于60%这
: 个值。 这样1 为大于,0 为小于。
: 用sas的logistic regression做回国,方法backward,因为不可能160个词汇都有预测
: 能力,所以希望削减variable数量。
: 模型stay的标准0.05,
: 结果如下:

r********n
发帖数: 6979
3
52个感觉是多了一点
我不用sas
所以不知道这个logistic regression是怎么得到这些系数的
你可以试试用一些Bayesian methods
加上一些df的penalty
比方LASSO之类的
应该得到的df要小一些
s*******o
发帖数: 392
4

他是这样得到这些系数的,因为我搜集了很多大概160个字符的频率作为预测的对象,
所以我让sas做backward variable selection,大体意思就是一开始sas默认有160个
variable都可以用预测,但是下一步就会筛选,看哪个var去掉后对model的影响最小,
这样一轮一轮的下来,最终当任何一个余下的var被去掉后都会对model的预测好坏有影
响的时候,就停下了。
我还有一个类似的预测,不过最后只剩下22个var,不知道如何interpret它们的好坏。

【在 r********n 的大作中提到】
: 52个感觉是多了一点
: 我不用sas
: 所以不知道这个logistic regression是怎么得到这些系数的
: 你可以试试用一些Bayesian methods
: 加上一些df的penalty
: 比方LASSO之类的
: 应该得到的df要小一些

a*z
发帖数: 294
5
you may try best subset method instead stepwise?
s*******o
发帖数: 392
6

hi,man, thanks lot for your reply first.
you are right, subset is a nice way. Correct me if I am wrong:
Subset: if you have 160 variables, the sas would go to see what is best for
modeling with 1 variable, what is best with 2 vars, what is best.....what is
best for 159 vars. And overall, it compare to see which is best out of best
of 160 way with 1, 2, 3, 4....160 variables to predict or modeling. I would
try.
But here I did not use stepwise, I use backward which method I read
somewhere telling me that it is the best if you have lot of variable and not
sure about their significance then you ask sas to modeling at beginning
including all of them then we based on criteria to reduce the number of
variables. They say it is the best way to not neglect some important
variable and it is kind of better off of backward over stepwise and forward
in logisticregression.
Man, how do you think about the graph above and 52 significant variable to
be used with high degree of freedom 52?
Thanks again.

【在 a*z 的大作中提到】
: you may try best subset method instead stepwise?
a***g
发帖数: 2761
7
拿cross validation套一下,估计能看出个大概

【在 s*******o 的大作中提到】
:
: hi,man, thanks lot for your reply first.
: you are right, subset is a nice way. Correct me if I am wrong:
: Subset: if you have 160 variables, the sas would go to see what is best for
: modeling with 1 variable, what is best with 2 vars, what is best.....what is
: best for 159 vars. And overall, it compare to see which is best out of best
: of 160 way with 1, 2, 3, 4....160 variables to predict or modeling. I would
: try.
: But here I did not use stepwise, I use backward which method I read
: somewhere telling me that it is the best if you have lot of variable and not

r********n
发帖数: 6979
8
backward selection我当然知道它是怎么做的
我是不大明白sas是怎么estimate regression coefficients
估计是用EM algorithm得到一个point estimate
如果用Bayesian的方法
可以加不同的prior
如果你想要少一点的predictor
那就可以加一些强一点的prior
这样大部分的系数都是接近与0
你试试LASSO
sas应该有LASSO的函数

【在 s*******o 的大作中提到】
:
: hi,man, thanks lot for your reply first.
: you are right, subset is a nice way. Correct me if I am wrong:
: Subset: if you have 160 variables, the sas would go to see what is best for
: modeling with 1 variable, what is best with 2 vars, what is best.....what is
: best for 159 vars. And overall, it compare to see which is best out of best
: of 160 way with 1, 2, 3, 4....160 variables to predict or modeling. I would
: try.
: But here I did not use stepwise, I use backward which method I read
: somewhere telling me that it is the best if you have lot of variable and not

p*******r
发帖数: 1951
9
你有没有检测一下correlation between independent variables?高度相关的变量可
以考虑合并,或者用一些消减变量的方法。
你有没有计算pseudo r square? 如果这个值比较低,那你这个模型做预测的准确性估
计不太乐观。反之,就还不错。
s*******o
发帖数: 392
10

啥意思,不懂啊?我就是用的cross validation,你套一下啥意思?

【在 a***g 的大作中提到】
: 拿cross validation套一下,估计能看出个大概
相关主题
紧急求助,问到MULTIPLE REGRESSION的题找工作总结 [下]
抓狂!为啥选出来的predictor都这么差one question about variable selection in SAS
有80个候选Predictors,怎么从中选<10个请教backward, forward and stepwise在做variable selection时的区别
进入Statistics版参与讨论
s*******o
发帖数: 392
11

好的,我这就去尝试一下lasso,bayesian怎么搞,sas里边具体函数是什么名字呢?

【在 r********n 的大作中提到】
: backward selection我当然知道它是怎么做的
: 我是不大明白sas是怎么estimate regression coefficients
: 估计是用EM algorithm得到一个point estimate
: 如果用Bayesian的方法
: 可以加不同的prior
: 如果你想要少一点的predictor
: 那就可以加一些强一点的prior
: 这样大部分的系数都是接近与0
: 你试试LASSO
: sas应该有LASSO的函数

f*********y
发帖数: 376
12
do you know how to do backward variable selection in STATA?

【在 s*******o 的大作中提到】
:
: 好的,我这就去尝试一下lasso,bayesian怎么搞,sas里边具体函数是什么名字呢?

a***d
发帖数: 336
13
it is maximum likelihood estimation for logistic regression.

【在 r********n 的大作中提到】
: backward selection我当然知道它是怎么做的
: 我是不大明白sas是怎么estimate regression coefficients
: 估计是用EM algorithm得到一个point estimate
: 如果用Bayesian的方法
: 可以加不同的prior
: 如果你想要少一点的predictor
: 那就可以加一些强一点的prior
: 这样大部分的系数都是接近与0
: 你试试LASSO
: sas应该有LASSO的函数

s*******o
发帖数: 392
14
没错,楼上的,就是靠maximum likelihood搞得,还有aic 以及-2log
s*******o
发帖数: 392
15
没错,楼上的,就是靠maximum likelihood搞得,还有aic 以及-2log
S*x
发帖数: 705
16
52个肯定多,有没有做proc corr来看variable之间的相关性? 有些时候很多variable是
成对成对出现的
你按照wald score排序来做一个cumulative wald score,肯定会发现最后
那些var都是用不到的
另外你这个图只显示model本身,logistic regression的somer's D呢? c score呢?
如果以上的数据都不错,你还得需要看validation来证明model是可用的

【在 s*******o 的大作中提到】
: 做logistic regression回国前准备:
: 1. independent variable:国外金融论坛有关交易词汇的统计:比如“trader,
: indicator, long, short, market, crazy”等有160个词汇的每日出现的相对频率,经
: 过normalization,比如trader 的出现的次数除以当天总的帖子数目。
: 2. 预测对象:binary variable: 明日的volatility是否是top 15%, 比如大于60%这
: 个值。 这样1 为大于,0 为小于。
: 用sas的logistic regression做回国,方法backward,因为不可能160个词汇都有预测
: 能力,所以希望削减variable数量。
: 模型stay的标准0.05,
: 结果如下:

s*******o
发帖数: 392
17

variable是
这个预测volatility的不太对。我现在改预测下一天eurusd是上涨还是下跌,这个感觉
比较靠谱。最后的结果是22个,但是还是penalty很大,可是sas已经不肯继续降低维度
了。那个c score是0.649左右,一般般。不过你也知道,我考虑只采用预测predicted
probability最高的10%,预测的精度在78左右,而且用到策略上也可以盈利,至于
validate,这个不就是cross-validation么?还需要怎么样的validate?

【在 S*x 的大作中提到】
: 52个肯定多,有没有做proc corr来看variable之间的相关性? 有些时候很多variable是
: 成对成对出现的
: 你按照wald score排序来做一个cumulative wald score,肯定会发现最后
: 那些var都是用不到的
: 另外你这个图只显示model本身,logistic regression的somer's D呢? c score呢?
: 如果以上的数据都不错,你还得需要看validation来证明model是可用的

s*******o
发帖数: 392
18
那些自变量的corr不高,最高23%,一般都在10%一下。
1 (共1页)
进入Statistics版参与讨论
相关主题
logistic, overfit了怎么办?有什么variable selection的方法可以用在Logistic regression上?
【大包子】Factor data analysis紧急求助,问到MULTIPLE REGRESSION的题
Gene expression =?= Variable selection抓狂!为啥选出来的predictor都这么差
做过regression的达人请进下,万分感谢有80个候选Predictors,怎么从中选<10个
请问关于LOGISTIC REGRESSION FORWARD VS BACKWARD找工作总结 [下]
问个logistic regression的问题。one question about variable selection in SAS
报面筋求实习合租 (转载)请教backward, forward and stepwise在做variable selection时的区别
logistic regression issue用LASSO选变量后重新fit regression有什么弊端?
相关话题的讨论汇总
话题: variable话题: regression话题: logistic话题: sas话题: best