Hypocenter Determination

Error Bars in X and Y

1 2 | ```
XYerror.bars(x, y, xlo = 0, xhi = 0, ylo = 0,
yhi = 0, pch = 1, col = 1, barw = 0.1, add = FALSE, ...)
``` |

`x` |
X-values |

`y` |
Y-values |

`xlo` |
X Lower limit of error bars |

`xhi` |
X Upper limit of error bars |

`ylo` |
Y Lower limit of error bars |

`yhi` |
Y Upper limit of error bars |

`pch` |
plotting character |

`col` |
color |

`barw` |
width of the bar (inches) |

`add` |
logical, add=FALSE starts a new plot |

`...` |
other plotting parameters |

graphical side effects

Jonathan M. Lees<jonathan.lees@unc.edu>

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | ```
set.seed(0)
zup = rnorm(10)
x = 1:10
y = 2*x+5+zup
ydown = rnorm(10)
ydown = ydown-min(ydown)+.2
yup = rnorm(10)
yup = yup-min(yup)+.2
zup = rnorm(10)
xup = zup-min(zup)+.5
xdown = rnorm(10)
xdown = xdown-min(xdown)+.2
#### example with different error on either side:
XYerror.bars(x, y, y-ydown, y+yup, x-xdown, x+xup,
pch = 1, col = 'brown' , barw = 0.1, add
= FALSE)
``` |

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.