Can you help me with a logistic regression?

3 ビュー (過去 30 日間)
Mario Trevino
Mario Trevino 2013 年 5 月 9 日
I need to solve the following system:
log(pR,i/pL,i)=SIGMA{ alpha_j [(rR,i-j)-(rL,i-j)]}+SIGMA{ beta_j [(cR,i-j)-(cL,i-j)]}+gamma
rR, rL, cR, cL: are known binary vectors (0,1) that describe the state of a system at different discrete times i=1,2,3,.... 'r' stands for reward, 'c' for choice, 'R' for right and 'L' for left (i.e. this is derived from a choice task with 2 options, L or R).
Note how the components for each summation are weighting the relative influence of past events as j increases.
PROBLEM 1: Im still uncertain on how to estimate the log odds (left portion of the equation). pR,i is the probability that cR,i==1.... and pL,i=1-pR,i. Likewise cL,i=1-cR,i.
PROBLEM 2: get alpha_j (function of j), beta_j (function of j), and gamma.

回答 (1 件)

Tom Lane
Tom Lane 2013 年 5 月 10 日
I don't understand your notation, in particular log(pR,i/pL,i). I guess you tried to explain that in PROBLEM 1, but I still don't understand what you intend to use as the response (or output or y) in this problem.
The Statistics Toolbox has a glmfit function (also GeneralizedLinearModel.fit) for fitting binary logistic regression. That can cope with estimating odds even when the inputs are all 0 or 1. But I suspect from the fact that I don't follow your notation that this will not be adequate.
Can you explain any further, or point to a reference?

カテゴリ

Help Center および File ExchangeParticle & Nuclear Physics についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by