Skip to content
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

Possible error in computing tau in BchronCalibrate? #12

Closed
wants to merge 1 commit into from

Conversation

ercrema
Copy link

@ercrema ercrema commented Sep 9, 2019

There is a possible error in the computation of tau in BchronCalibrate(). This was detected when comparing Bchron to rcarbon and OxCal (via oxcAAR). There are still some differences after the fix but this is presumably due to the use of the t distribution?

library(Bchron)
library(rcarbon)
library(oxcAAR)


x1=BchronCalibrate(4000,40,calCurves='intcal13')
x2=calibrate(4000,40)
quickSetupOxcal()
x3=oxcalCalibrate(4000,40)


plot(x1$Date1$ageGrid,x1$Date1$densities,type='l')
lines(x2$grids[[1]][,1],x2$grids[[1]][,2],col='red',lty=2)
oxcalDF= x3[[1]][6][[1]]
lines(abs(round(oxcalDF[,1])-1950), oxcalDF[,2],lty=3,col='blue')

@andrewcparnell
Copy link
Owner

Thanks for the comment. The use of the t-distribution in Bchron is deliberate. You don't truly know the age sd for a date so really you should use a t-distribution rather than a Gaussian. I think there's a paper by Andres Christen which discusses this issue but I don't have it to hand. The differences are likely very slight.

@ercrema
Copy link
Author

ercrema commented Mar 4, 2020

Oh, by no mean I wasn't referring much about the use of the t-distribution but more about how tau was computed (without squaring the error term in the calibration curve).

@andrewcparnell
Copy link
Owner

Wow, and apologies for not fulling getting your query. Thank you so much for spotting this. I must have introduced this bug back in V4 and I'm now on version 4.5!

Fixed on GitHub and will be updating this ASAP on CRAN.

@ercrema
Copy link
Author

ercrema commented Mar 5, 2020

No problems (I was a bit unclear...) and thanks for developing the package!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants