mirror of
https://github.com/sensebox/opensensmapr
synced 2025-04-19 16:08:12 +02:00
expose mar for plot.osem_measurements(), fixes #12
This commit is contained in:
parent
8f70a242d0
commit
416d986c11
1 changed files with 3 additions and 2 deletions
|
@ -1,7 +1,7 @@
|
||||||
#' @export
|
#' @export
|
||||||
plot.osem_measurements = function (x, ...) {
|
plot.osem_measurements = function (x, ..., mar = c(2,4,1,1)) {
|
||||||
oldpar = par()
|
oldpar = par()
|
||||||
par(mar = c(2,4,1,1))
|
par(mar = mar)
|
||||||
plot(value~createdAt, x, col = factor(x$sensorId), xlab = NA, ylab = x$unit[1], ...)
|
plot(value~createdAt, x, col = factor(x$sensorId), xlab = NA, ylab = x$unit[1], ...)
|
||||||
par(mar = oldpar$mar)
|
par(mar = oldpar$mar)
|
||||||
invisible(x)
|
invisible(x)
|
||||||
|
@ -10,6 +10,7 @@ plot.osem_measurements = function (x, ...) {
|
||||||
#' @export
|
#' @export
|
||||||
print.osem_measurements = function (x, ...) {
|
print.osem_measurements = function (x, ...) {
|
||||||
print.data.frame(x, ...)
|
print.data.frame(x, ...)
|
||||||
|
invisible(x)
|
||||||
}
|
}
|
||||||
|
|
||||||
#' Converts a foreign object to an osem_measurements data.frame.
|
#' Converts a foreign object to an osem_measurements data.frame.
|
||||||
|
|
Loading…
Add table
Reference in a new issue