Commit 36c085eb by Eric Coissac

Some changes in doc

parent 748acd07
...@@ -17,6 +17,7 @@ NULL ...@@ -17,6 +17,7 @@ NULL
#' #'
#' @author Eric Coissac #' @author Eric Coissac
#' @author Christelle Gonindard-Melodelima #' @author Christelle Gonindard-Melodelima
#' @rdname rep_matrix
#' #'
.rep_matrix = function(x,length.out) { .rep_matrix = function(x,length.out) {
...@@ -49,13 +50,13 @@ NULL ...@@ -49,13 +50,13 @@ NULL
dxi=dim(xi) dxi=dim(xi)
rownamesi = rownames(xi) rownamesi = rownames(xi)
colnamesi = colnames(xi) colnamesi = colnames(xi)
xi = as.numeric(xi) xi = as.numeric(xi)
dim(xi)=dxi dim(xi)=dxi
rownames(xi) = rownamesi rownames(xi) = rownamesi
colnames(xi) = colnamesi colnames(xi) = colnamesi
N = nrow(xi) N = nrow(xi)
if (nrows > 0L && N < nrows) { if (nrows > 0L && N < nrows) {
...@@ -94,7 +95,7 @@ NULL ...@@ -94,7 +95,7 @@ NULL
} }
else else
rownames(x)=value rownames(x)=value
x x
} }
...@@ -108,15 +109,15 @@ NULL ...@@ -108,15 +109,15 @@ NULL
.siteSelect = function(x,select) { .siteSelect = function(x,select) {
if (inherits(x,'dist')) if (inherits(x,'dist'))
as.dist(as.matrix(x)[select,select,drop=FALSE]) as.dist(as.matrix(x)[select,select,drop=FALSE])
else else
x[select,,drop=FALSE] x[select,,drop=FALSE]
} }
#' Build a procmod.frame data structure. #' The procmod.frame data structure.
#' #'
#' @author Eric Coissac #' @author Eric Coissac
#' @author Christelle Gonindard-Melodelima #' @author Christelle Gonindard-Melodelima
...@@ -184,20 +185,19 @@ procmod.frame = function(..., ...@@ -184,20 +185,19 @@ procmod.frame = function(...,
return(make_subS3Class(value, "procmod.frame")) return(make_subS3Class(value, "procmod.frame"))
} }
#' Check if an object is a Matrix Frame.
#' #'
#' @author Eric Coissac #' Check if an object is a ProcMod Frame.
#' @author Christelle Gonindard-Melodelima #'
#' @rdname procmod.frame
#' @export #' @export
is.procmod.frame = function(x) { is.procmod.frame = function(x) {
inherits(x, "procmod.frame") inherits(x, "procmod.frame")
} }
#'
#' Coerce to a ProcMod Frame. #' Coerce to a ProcMod Frame.
#' #'
#' @author Eric Coissac #' @rdname procmod.frame
#' @author Christelle Gonindard-Melodelima
#' @export #' @export
as.procmod.frame = function(data,...) { as.procmod.frame = function(data,...) {
UseMethod("as.procmod.frame",data) UseMethod("as.procmod.frame",data)
...@@ -384,4 +384,3 @@ as.list.procmod.frame = function(x, ...) { ...@@ -384,4 +384,3 @@ as.list.procmod.frame = function(x, ...) {
class(x)='list' class(x)='list'
return(x) return(x)
} }
...@@ -2,13 +2,23 @@ ...@@ -2,13 +2,23 @@
% Please edit documentation in R/procmod.frame.R % Please edit documentation in R/procmod.frame.R
\name{procmod.frame} \name{procmod.frame}
\alias{procmod.frame} \alias{procmod.frame}
\title{Build a procmod.frame data structure.} \alias{is.procmod.frame}
\alias{as.procmod.frame}
\title{The procmod.frame data structure.}
\usage{ \usage{
procmod.frame(..., row.names = NULL, check.rows = FALSE, procmod.frame(..., row.names = NULL, check.rows = FALSE,
check.names = TRUE, reorder.rows = FALSE) check.names = TRUE, reorder.rows = FALSE)
is.procmod.frame(x)
as.procmod.frame(data, ...)
} }
\description{ \description{
Build a procmod.frame data structure. The procmod.frame data structure.
Check if an object is a ProcMod Frame.
Coerce to a ProcMod Frame.
} }
\author{ \author{
Eric Coissac Eric Coissac
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment