Live data from Hacker News

How Khan Academy is using machine learning to assess student mastery

david-hu.com

21–30 of 48 posts

Re: How Khan Academy is using machine learning to assess student mastery

#21
post #19

Earlier quoted context omitted.

I'm totally pimping my own warez here: http://untyped.com/untyping/2011/02/11/stop-ab-testing-and-m... http://www.mynaweb.com/blog/2011/09/13/myna-vs-ab.html

(Reads links.) I've been going around telling people for a while that A/B testing is non-Bayesian but I didn't realize there was an off-the-shelf solution! You need to pimp your wares more often.

It doesn't sound terribly Bayesian to me. From one of his pages:

However, the significance calculation makes a critical assumption that you have probably violated without even realizing it: that the sample size was fixed in advance. If instead of deciding ahead of time, “this experiment will collect exactly 1,000 observations,” you say, “we’ll run it until we see a significant difference,” all the reported significance levels become meaningless.

The original intent of the experimenter shouldn't affect his conclusions!

With that said, I'm not sure what the proper Bayesian answer is. If I were to stop my experiments every time that P(X|D) Incidentally, you (Eliezer) had a nice post where you explained the problem in detail (something about two doctors doing an experiment 50 times with different "stopping rules", who get the same data), but I couldn't find it.

[1] EDIT: On further thought, there wouldn't be any bias if I do the correct thing and report my uncertainty: P(X|D) = 0.04. The "repeated significance testing errors" comes from converting P = 0.04 into an absolute statement "X is true". Then the stopping rule will affect the statistics.

Re: How Khan Academy is using machine learning to assess student mastery

#22
To solve the problem that people dont do more problems after becoming proficient, consider forcing a randomized subset to solve one extra problem for aquiring proficiency. Don't tell the users when this happens though, just show the bar as not quite full

Re: How Khan Academy is using machine learning to assess student mastery

#23
post #21
post #19

Earlier quoted context omitted.

(Reads links.) I've been going around telling people for a while that A/B testing is non-Bayesian but I didn't realize there was an off-the-shelf solution! You need to pimp your wares more often.

It doesn't sound terribly Bayesian to me. From one of his pages: However, the significance calculation makes a critical assumption that you have probably violated without even realizing it: that the sample size was fixed in advance. If instead of deciding ahead of time, “this experiment will collect exactly 1,000 observations,” you say, “we’ll run it until we see a significant difference,” all the reported significan…

Is this it? http://yudkowsky.net/rational/bayes

Re: How Khan Academy is using machine learning to assess student mastery

#24
My question is how does time dependency work in this case. I am trying to wrap my head around how a prediction engine would work when your assessing students on the basis of not just past/current performance but also how much time their taking while answering each question.

I think you can model for randomness (kids getting lucky while answering a question), but if you can somehow add time-dependency to the model, then your predictability would be higher (of course this is pure speculation).

Does anyone have a good model I can look at? Any help would be appreciated.

Re: How Khan Academy is using machine learning to assess student mastery

#25
post #21

Earlier quoted context omitted.

It doesn't sound terribly Bayesian to me. From one of his pages: However, the significance calculation makes a critical assumption that you have probably violated without even realizing it: that the sample size was fixed in advance. If instead of deciding ahead of time, “this experiment will collect exactly 1,000 observations,” you say, “we’ll run it until we see a significant difference,” all the reported significan…

Is this it? http://yudkowsky.net/rational/bayes

Nah, it's not. The original had a setup like:

Doctor A decides to test a cure on 50 patients. 40 have gotten better. Doctor B independently decides to test the same cure on his patients. He will stop once he has reached 'significance'. Coincidentally, the results become significant at the 50th patient, and he also has a 40/50 success rate.

Doctor A says "I followed a fixed testing procedure, and the statistical analysis says that my data is not significant. We need more experiments."

Doctor B says "I followed an optional stopping procedure, and the statistical analysis says that my data is not significant: the cure is good."

A Bayesian would claim that if they both have the same data, then they should reach the same conclusion, regardless of their intent.

A "frequentist" would uphold that the doctors can legitimately disagree. I don't know much about frequentism, but it's the dominant perspective in statistics. Everything I've read about A/B testing is frequentist.

Re: How Khan Academy is using machine learning to assess student mastery

#26
post #21
post #19

Earlier quoted context omitted.

(Reads links.) I've been going around telling people for a while that A/B testing is non-Bayesian but I didn't realize there was an off-the-shelf solution! You need to pimp your wares more often.

It doesn't sound terribly Bayesian to me. From one of his pages: However, the significance calculation makes a critical assumption that you have probably violated without even realizing it: that the sample size was fixed in advance. If instead of deciding ahead of time, “this experiment will collect exactly 1,000 observations,” you say, “we’ll run it until we see a significant difference,” all the reported significan…

Changing stopping rules after seeing the data creates bias/distortions. One does have to set the rules in advance, that's not a mistake.

Consider a data set consisting of a single license plate number. (This example is from Richard Feynman.)

If you set the rules in retrospect, you can go "Wow, what were the odds my one license plate would be XJKDL-2342-KE? One in a million?" But that's wrong.

On the other hand if you predicted XJKDL-2342-KE in advance, then the same data point would have a different meaning. How did you predict it?

Patterns that you can predict in advance are different from ones you can find in retrospect after looking through whatever results you get. So the same data point -- XJKDL-2342-KE -- can take on different meaning depending on the original intent and design of the experimenter.

People make this mistake all the time with more mundane examples. Like they will roll snake eyes three times in a row, then calculate the odds of that happening, and then says "wow 1/6^6, there was such a minuscule chance i'd get screwed like this". but they're just wrong. ANY exact ordering of the 6 individual dice roles has a 1/6^6 chance of happening, and you have to get one of the "unlikely" results.

To help make this more intuitive, consider that they would have been surprised by rolling all 2s, or all 3s, or various other patterns. So you at least would have to figure out how many outcomes they'd deem surprising and figure out what proportion of the possibilities are in that category. And then take into account all the rolls they made when they weren't surprised and didn't record any data...

Re: How Khan Academy is using machine learning to assess student mastery

#27
post #25

Earlier quoted context omitted.

Is this it? http://yudkowsky.net/rational/bayes

Nah, it's not. The original had a setup like: Doctor A decides to test a cure on 50 patients. 40 have gotten better. Doctor B independently decides to test the same cure on his patients. He will stop once he has reached 'significance'. Coincidentally, the results become significant at the 50th patient, and he also has a 40/50 success rate. Doctor A says "I followed a fixed testing procedure, and the statistical analy…

Sounds like this: http://lesswrong.com/lw/mt/beautiful_probability/

Re: How Khan Academy is using machine learning to assess student mastery

#28
post #25

Earlier quoted context omitted.

Nah, it's not. The original had a setup like: Doctor A decides to test a cure on 50 patients. 40 have gotten better. Doctor B independently decides to test the same cure on his patients. He will stop once he has reached 'significance'. Coincidentally, the results become significant at the 50th patient, and he also has a 40/50 success rate. Doctor A says "I followed a fixed testing procedure, and the statistical analy…

Sounds like this: http://lesswrong.com/lw/mt/beautiful_probability/

Yes! Thank you.

Re: How Khan Academy is using machine learning to assess student mastery

#29
post #21

Earlier quoted context omitted.

It doesn't sound terribly Bayesian to me. From one of his pages: However, the significance calculation makes a critical assumption that you have probably violated without even realizing it: that the sample size was fixed in advance. If instead of deciding ahead of time, “this experiment will collect exactly 1,000 observations,” you say, “we’ll run it until we see a significant difference,” all the reported significan…

Changing stopping rules after seeing the data creates bias/distortions. One does have to set the rules in advance, that's not a mistake. Consider a data set consisting of a single license plate number. (This example is from Richard Feynman.) If you set the rules in retrospect, you can go "Wow, what were the odds my one license plate would be XJKDL-2342-KE? One in a million?" But that's wrong. On the other hand if you…

Thank you for your comments - there's a lot of issues about this problem that I'm not entirely comfortable with.

With that said, I'm not sure that I see the connection between what you're arguing and the significance problem in the original. What do you think of the example with the two doctors? http://lesswrong.com/lw/mt/beautiful_probability/

Changing stopping rules after seeing the data creates bias/distortions

We're talking about a fixed stopping rule, which depends on the data.

Re: How Khan Academy is using machine learning to assess student mastery

#30
post #29

Earlier quoted context omitted.

Changing stopping rules after seeing the data creates bias/distortions. One does have to set the rules in advance, that's not a mistake. Consider a data set consisting of a single license plate number. (This example is from Richard Feynman.) If you set the rules in retrospect, you can go "Wow, what were the odds my one license plate would be XJKDL-2342-KE? One in a million?" But that's wrong. On the other hand if you…

Thank you for your comments - there's a lot of issues about this problem that I'm not entirely comfortable with. With that said, I'm not sure that I see the connection between what you're arguing and the significance problem in the original. What do you think of the example with the two doctors? http://lesswrong.com/lw/mt/beautiful_probability/ Changing stopping rules after seeing the data creates bias/distortions We…

Oh, I see what you mean about fixed. It's hard to generalize about all data-dependent stopping rules. I do think the one that says "If I get one conclusion, stop. If I get the other, keep trying," has got to be a bad idea! It prevents you from possibly finishing an experiment that concludes you're wrong. The possibility of not terminating seems especially problematic. But if the rule was more like "Roll 10 dice. If at least one came up 6, roll one more die." then it might be harmless and just complicate analyzing the results.

I think that even if you get the same data set as your results, as in the linked doctor example, the stopping rule does matter. A reason for this is that it affects the repeatability of experiments. Experiments ought to be repeatable (within margins of error, and using all the same procedures including stopping rules). Let's consider what could happen with repeat trials. Suppose the medicine almost but not quite works according to the standard you're trying to test for that will make the medicine considered a success (cures at least 60 out of 100 people, on average -- not the most realistic standard, but that's not important). Also suppose the data set had 60 cures exactly, not 70 (the following is technically possible, but unlikely, with 70).

So, the first experiment with a fixed N=100 will not be repeatable. Slightly too few people will be cured in future trials. The success on the first attempt was good luck within the margin for error (the real average cure rate is 59 out of 100).

The second experiment, however, will eventually report that the medicine works on at least 60% of patients on average in all 10 (or whatever) repeat trials, even though this is false. (I think. Maybe they won't make that false "on average" claim but will conclude something different instead? What?) The reason this will happen is basically the same reason that if you flip a coin enough you random walk away from the average (and eventually visit both sides of the average). And because the real cure proportion is so near the goal, there's a pretty good chance you could do a lot of repeat trials without any stalling out for years (which might clue some people in to the problem, though if they strictly ignore data from studies that haven't stopped yet, then maybe it wouldn't).

Similarly, imagine a study of coins which had a stopping rule to stop whenever you have at least 60% heads. You'll always be able to get that result and conclude the coin is biased, even if all coins used are fair. You'll often be able to get that result pretty quickly (and actually if you don't get it quickly, but hover around average, the expected time to get it will keep getting worse. But I bet we could come up with an example that doesn't have that property. Or we could consider 20 research groups, 15 of which report coins are biased and 5 of which never publish.). But the point is their result, claiming coins are biased, may be wrong. Even the possibility of the method getting a wrong answer, without anyone having made a mistake in doing it, is a major problem!

If someone said, "Never mind their stopping rules, I want to salvage their coin flipping data and use it for my other project" I think they would have a serious problem because it's not a proper random set of coin flip data but is instead limited to various possible sequences of flips and not others.

Now it could always be that trials with bad stopping rules get lucky and are correct, and using or believing their data won't work out badly. Their data set could happen to be identical to one that is properly collected. But I think one always has to fear the possibility that they didn't get lucky and their stopping conditions have spoiled the data (especially when you don't have a properly done trial with identical results to compare with) just as the people trying to prove coins are biased could easily spoil their data using fixed but unreasonable stopping conditions.

Post reply on HN