-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Significantly Different Results Based on R Version #9
Comments
I'm not sure what might be causing that. The first place I'd check is probably to make 100% sure that the version of aRpsDCA is the same in both cases, and that the exact same data is being provided to the relevant functions. It's possible that the functionality of |
I'll look into the versions and see but the data is the exact same. When you pop it out of Power BI it creates the datasets for your in a temp file. At first I was dumbfounded but realized it had to be a version thing because everything else was identical. Thank you for the quick response! |
By the way if I changed R studio to run on 4.2.2 it matched the PowerBI results, so it's something in aRpsDCA or nlminb. |
That is just super weird... |
Version Data.xlsx |
I'm assuming the different results are in a best-overall-fit based on raw rate/time data (i.e. the sessionInfo()
data <- read.delim(sep='\t', text='t\tq\n0\t15609\n0.235616438\t15609\n0.487671233\t17002\n0.734246575\t10167\n0.969863014\t7344\n1.221917808\t5256\n1.473972603\t4582\n1.583561644\t3959\n1.739726027\t4482\n1.915068493\t3705\n2.126027397\t3452\n2.375342466\t3637\n2.62739726\t3239\n2.824657534\t3517\n3.032876712\t2496\n3.282191781\t1729\n3.534246575\t1655\n\n')
best <- best.fit(q=data$q, t=data$t)
print(best)
best.h2e <- best.hyp2exp(q=data$q, t=data$t)
print(best.h2e) |
Well this is interesting: 4.0.2: `> sessionInfo() Matrix products: default locale: attached base packages: other attached packages: loaded via a namespace (and not attached):
$sse
$sse 4.2.2:
Matrix products: default locale: attached base packages: other attached packages: loaded via a namespace (and not attached):
$sse
$sse |
Yes the difference is occurring using best.fit.from.Np.with.buildup but I'm plotting the outputs from all three methods to see the difference and it's not like there's a better option that it is ignoring. |
The "with buildup" part is suggestive. That part of the code has been something of a hotspot for errors. Would you mind running the example script above again, but edited as follows?
|
For what it's worth, on my machine, I get:
4.2.2:
I also get the same rate forecasts out of both environments for the resulting decline. |
I got the same results you posted. |
That would seem to imply that the issue lies elsewhere. I think the next step would have to be to verify that the exact same data is being sent to the exact same functions in each environment, and arriving at a script that reliably reproduces the issue. |
First off I just want to say thank you for putting this out there, it's fantastic. Built a script to run in R 4.0.2 and it works great. I then put it into PowerBI and noticed that my answers were significantly different, like 30% lower and the matches weren't very accurate visually. I plopped it out of PowerBI and into R Studio and all of a sudden it was matching again without changing any code, which is when I realized PowerBI was using R 4.2.2 instead of 4.0.2. Now that I noticed this I can avoid issues going forward but do you have any idea why the version change would affect the output so significantly?
The text was updated successfully, but these errors were encountered: