Can I Plot Log (x) with Error Bars without Changing err_x Values?

  • Thread starter Thread starter Lorna
  • Start date Start date
  • Tags Tags
    Error Log
AI Thread Summary
To plot log(x) with error bars, adjustments to the error values (err_x) are necessary to maintain accuracy. It is suggested to use log(1 + error) for positive errors and -log(1 - error) for negative errors to keep error representation consistent. The inclusion of '1' in the calculations ensures that error bars approach zero as the error itself approaches zero, preventing calculation issues with negative logs. Using a smaller or larger number could lead to misrepresentation of small errors. This approach effectively balances the error bars while plotting the logarithmic values.
Lorna
Messages
44
Reaction score
0
Hello,

I have a column of 'x' values, each with an error 'err_x' serving as error bars.

My question is: If I need to plot 'log(x)', Do I need to make any changes to 'err_x' to reflect the log operation before plotting them as error bars ?

Thank you in advance

Lorna
 
Physics news on Phys.org
I would plot log(1 + error) for positive error and -log(1 - error) for negative error. That way error is on the same scale.
 
What is the significance of the '1' ? and why not just log(error)?
 
Lorna said:
What is the significance of the '1' ? and why not just log(error)?

Why don't you pick some errors in -1 < e < 1 and see for yourself?
 
Thank you, althought I still don't understand why "1" not another number
 
Lorna said:
Thank you, althought I still don't understand why "1" not another number

It's the only number that will make the error bars tend to 0 as the error approaches 0. With a smaller value very small errors won't show up at all (calculation error trying to take a negative log); with a larger value errors won't ever get closer than a certain distance from the point no matter how small the errors are.
 
Now I see. Thank you SO MUCH!
 
Back
Top