Skip to content

Commit

Permalink
Chipping away at cran check warnings #38
Browse files Browse the repository at this point in the history
  • Loading branch information
emhart committed Mar 1, 2015
1 parent 8957512 commit 41e4f99
Show file tree
Hide file tree
Showing 15 changed files with 74 additions and 13 deletions.
7 changes: 3 additions & 4 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,12 @@ Title: <short description here>
Version: 0.1.0
Date: 2014-02-16
BugReports: https://github.com/GotelliLab/EcoSimR/issues
Authors@R: c(person("Nick", "Gotelli", role = c("aut", "cre"),
Authors@R: c(person("Nick", "Gotelli", role = c("aut"),
email = "ngotelli@uvm.edu"),
person("Edmund", "Hart", role = "aut",
person("Edmund", "Hart", role = c("aut","cre"),
email = "edmund.m.hart@gmail.com"),
person("Aaron", "Ellison", role = c("aut","cre"),
person("Aaron", "Ellison", role = c("aut"),
email = "aellison@fas.harvard.edu") )
Maintainer: Edmund Hart <edmund.m.hart@gmail.com>
LazyLoad: yes
LazyData: yes
Description: <longer description here>
Expand Down
1 change: 1 addition & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

S3method(plot,coocnullmod)
S3method(plot,nichenullmod)
S3method(plot,sizenullmod)
S3method(summary,coocnullmod)
S3method(summary,nichenullmod)
S3method(summary,sizenullmod)
Expand Down
8 changes: 6 additions & 2 deletions R/coccurrence_null.R
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ cooc_null_model <- function(speciesData, algo = "sim1", metric = "c_score", nRep

#' Generic function for calculating null model summary statistics
#' @description Takes as input a list of Null.Model.Out, with Obs, Sim, Elapsed Time, and Time Stamp values
#' @param object the null model object to print a summary.
#' @export

summary.coocnullmod <- function(object,...)
Expand Down Expand Up @@ -111,8 +112,11 @@ summary.coocnullmod <- function(object,...)



#' Null Model Plot function
#' @description Generic function for plotting a histogram of simulated values Takes as input a list of Null.Model.Out, with Obs and Sim values
#' Co-Occurrence Model Plot function
#' @description Plot co-occurrence null model object.
#' @param x the null model to plot
#' @param type the type of null plot to make. See details for more information
#' @details the valid types for size are "hist" to show a histogram and "size" to show a sample size null model.
#' @export


Expand Down
6 changes: 5 additions & 1 deletion R/niche_overlap_null.R
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ niche_null_model <- function(speciesData, algo = "ra3", metric = "pianka", nReps

#' Generic function for calculating null model summary statistics
#' @description Takes as input a list of Null.Model.Out, with Obs, Sim, Elapsed Time, and Time Stamp values
#' @param object the null model object to print a summary of.
#' @export

summary.nichenullmod <- function(object,...)
Expand Down Expand Up @@ -83,8 +84,11 @@ summary.nichenullmod <- function(object,...)



#' Null Model Plot function
#' Niche Null Model Plot function
#' @description Generic function for plotting a histogram of simulated values Takes as input a list of Null.Model.Out, with Obs and Sim values
#' @param x the null model to plot
#' @param type the type of null plot to make. See details for more information
#' @details the valid types for size are "hist" to show a histogram and "niche" to show a sample draw from the null model.
#' @export


Expand Down
3 changes: 2 additions & 1 deletion R/sim9fast.R
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#' Sim9.fast function
#' @description Special implementation of sequential swap algorithm
#' @description Special implementation of sequential swap algorithm.

#' @export


Expand Down
10 changes: 9 additions & 1 deletion R/sizeratio_null.R
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ size_null_model <- function(speciesData, algo = "size_uniform", metric = "var_ra

#' Generic function for calculating null model summary statistics
#' @description Takes as input a list of Null.Model.Out, with Obs, Sim, Elapsed Time, and Time Stamp values
#' @param object the null model object to print a summary of.
#' @export

summary.sizenullmod <- function(object,...)
Expand Down Expand Up @@ -95,9 +96,16 @@ summary.sizenullmod <- function(object,...)
}



#' plot a size null model
#' @description plot a variety of size null models
#' @param x the null model to plot
#' @param type the type of null plot to make. See details for more information
#' @details the valid types for size are "hist" to show a histogram and "size" to show a sample size null model.
#' @export

plot.sizenullmod <- function(x, type = "hist",...)
{
cat("in here")
nullmodObj <- x
if(type == "hist"){
par(mfrow=c(1,1))
Expand Down
Binary file modified data/datasets.rda
Binary file not shown.
Binary file removed datasets.rda
Binary file not shown.
12 changes: 10 additions & 2 deletions man/plot.coocnullmod.Rd
Original file line number Diff line number Diff line change
@@ -1,11 +1,19 @@
% Generated by roxygen2 (4.0.2): do not edit by hand
\name{plot.coocnullmod}
\alias{plot.coocnullmod}
\title{Null Model Plot function}
\title{Co-Occurrence Model Plot function}
\usage{
\method{plot}{coocnullmod}(x, type = "hist", ...)
}
\arguments{
\item{x}{the null model to plot}

\item{type}{the type of null plot to make. See details for more information}
}
\description{
Generic function for plotting a histogram of simulated values Takes as input a list of Null.Model.Out, with Obs and Sim values
Plot co-occurrence null model object.
}
\details{
the valid types for size are "hist" to show a histogram and "size" to show a sample size null model.
}

10 changes: 9 additions & 1 deletion man/plot.nichenullmod.Rd
Original file line number Diff line number Diff line change
@@ -1,11 +1,19 @@
% Generated by roxygen2 (4.0.2): do not edit by hand
\name{plot.nichenullmod}
\alias{plot.nichenullmod}
\title{Null Model Plot function}
\title{Niche Null Model Plot function}
\usage{
\method{plot}{nichenullmod}(x, type = "hist", ...)
}
\arguments{
\item{x}{the null model to plot}

\item{type}{the type of null plot to make. See details for more information}
}
\description{
Generic function for plotting a histogram of simulated values Takes as input a list of Null.Model.Out, with Obs and Sim values
}
\details{
the valid types for size are "hist" to show a histogram and "niche" to show a sample draw from the null model.
}

19 changes: 19 additions & 0 deletions man/plot.sizenullmod.Rd
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
% Generated by roxygen2 (4.0.2): do not edit by hand
\name{plot.sizenullmod}
\alias{plot.sizenullmod}
\title{plot a size null model}
\usage{
\method{plot}{sizenullmod}(x, type = "hist", ...)
}
\arguments{
\item{x}{the null model to plot}

\item{type}{the type of null plot to make. See details for more information}
}
\description{
plot a variety of size null models
}
\details{
the valid types for size are "hist" to show a histogram and "size" to show a sample size null model.
}

2 changes: 1 addition & 1 deletion man/sim9.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@ sim9(speciesData, algo, metric, nReps = 1000, rowNames = TRUE,
saveSeed = FALSE, burn_in = 0)
}
\description{
Special implementation of sequential swap algorithm
Special implementation of sequential swap algorithm.
}

3 changes: 3 additions & 0 deletions man/summary.coocnullmod.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
\usage{
\method{summary}{coocnullmod}(object, ...)
}
\arguments{
\item{object}{the null model object to print a summary.}
}
\description{
Takes as input a list of Null.Model.Out, with Obs, Sim, Elapsed Time, and Time Stamp values
}
Expand Down
3 changes: 3 additions & 0 deletions man/summary.nichenullmod.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
\usage{
\method{summary}{nichenullmod}(object, ...)
}
\arguments{
\item{object}{the null model object to print a summary of.}
}
\description{
Takes as input a list of Null.Model.Out, with Obs, Sim, Elapsed Time, and Time Stamp values
}
Expand Down
3 changes: 3 additions & 0 deletions man/summary.sizenullmod.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
\usage{
\method{summary}{sizenullmod}(object, ...)
}
\arguments{
\item{object}{the null model object to print a summary of.}
}
\description{
Takes as input a list of Null.Model.Out, with Obs, Sim, Elapsed Time, and Time Stamp values
}
Expand Down

0 comments on commit 41e4f99

Please sign in to comment.