Add mad_to_a95 conversion function#816
Conversation
Implements conversion from MAD (or aMAD) to a95 using Khokhlov & Hulot (2016, Table 8)
|
Thanks for this pull request! I think it would be better to use the asymptotic n=100 value for all n_steps that are greater than 16. The value of 16 and the value of 100 are close so this is an appropriate approximation. I have made a commit that removes the strict logic and uses this asymptotic approach instead. I have also had it return a value error for n_steps < 3. This simplifies the API. |
|
The other thing that we need to update is to enable the function to take an array for n_steps values if there is an array of MAD values. It is common with a set of data for there to be different n_steps for different specimens that would have different MADs. |
|
I have now added the ability for the function to accept an array of n_steps values that can correspond with the MAD values. It can either accept a single value as before or accept an array of matching length. @LenGallo Can you give the updated function a test and make any additional changes you see fit? |
|
Thanks @Swanson-Hysell for improving the implementation! I pulled the changes and tested |
Implements conversion from MAD (or aMAD) to a95 using Khokhlov & Hulot (2016, Table 8)