Skip to content
This repository has been archived by the owner on May 10, 2022. It is now read-only.

Commit

Permalink
updated documentation, tested checks. Waiting on an API issue with me…
Browse files Browse the repository at this point in the history
…trics otherwise package is near completion. Still need to add in collection_creation and some visualization.
  • Loading branch information
karthik committed Sep 28, 2012
1 parent 0ebb2fd commit 5c8daf4
Show file tree
Hide file tree
Showing 5 changed files with 61 additions and 3 deletions.
1 change: 1 addition & 0 deletions DESCRIPTION
Expand Up @@ -25,6 +25,7 @@ Imports:
plyr
Collate:
'getMetrics.R'
'collection.R'
'api_info.R'
'tiID.R'
'ti_providers.R'
2 changes: 2 additions & 0 deletions NAMESPACE
@@ -1,5 +1,7 @@
export(IS_providers)
export(ISid)
export(about_IS)
export(collection_metrics)
export(create_ISid)
export(metrics)
export(save_collection)
6 changes: 3 additions & 3 deletions R/collection.R
@@ -1,8 +1,8 @@
#' Retrives metadata on a valid Impact Story collecISon ID
#'
#' @return a \code{list} with the following fields: \item{_id}{id #} \item{_rev}{revision #} \item{created}{created on} \item{ip_address}{ip address of creaISon} \item{items}{list of items} \item{key_hash}{} \item{last_modified}{} \item{owner}{} \item{IStle}{} \item{type}{}.
#' @param collecISon_id A Impact Story collecISon id
#' @param as.csv Default is \code{FALSE}. Set to \code{TRUE} to return a .csv file. Use in conjuncISon with \code{\link{save_collecISon}}
#' @return a \code{list} with the following fields: \item{_id}{id #} \item{_rev}{revision #} \item{created}{created on} \item{ip_address}{ip address of creaISon} \item{items}{list of items} \item{key_hash}{} \item{last_modified}{} \item{owner}{} \item{title}{} \item{type}{}.
#' @param collection_id A Impact Story collecISon id
#' @param as.csv Default is \code{FALSE}. Set to \code{TRUE} to return a .csv file. Use in conjuncISon with \code{\link{save_collection}}
#' @export
#' @examples \dontrun{
#' collection_metrics('kn5auf')
Expand Down
33 changes: 33 additions & 0 deletions man/collection_metrics.Rd
@@ -0,0 +1,33 @@
\name{collection_metrics}
\alias{collection_metrics}
\title{Retrives metadata on a valid Impact Story collecISon ID}
\usage{
collection_metrics(collection_id = NULL, as.csv = FALSE)
}
\arguments{
\item{collection_id}{A Impact Story collecISon id}

\item{as.csv}{Default is \code{FALSE}. Set to \code{TRUE}
to return a .csv file. Use in conjuncISon with
\code{\link{save_collection}}}
}
\value{
a \code{list} with the following fields: \item{_id}{id #}
\item{_rev}{revision #} \item{created}{created on}
\item{ip_address}{ip address of creaISon}
\item{items}{list of items} \item{key_hash}{}
\item{last_modified}{} \item{owner}{} \item{title}{}
\item{type}{}.
}
\description{
Retrives metadata on a valid Impact Story collecISon ID
}
\examples{
\dontrun{
collection_metrics('kn5auf')
}
}
\author{
Karthik Ram \email{karthik.ram@gmail.com}
}

22 changes: 22 additions & 0 deletions man/save_collection.Rd
@@ -0,0 +1,22 @@
\name{save_collection}
\alias{save_collection}
\title{Saves metrics from a collection to a csv file}
\usage{
save_collection(cid = NULL, file = NULL)
}
\arguments{
\item{cid}{A valid Impact Story collection ID}

\item{file}{A filename for the \code{csv} file including
path. If left blank, the file is named after the
collection and stored in the current working directory.}
}
\description{
Saves metrics from a collection to a csv file
}
\examples{
\dontrun{
save_collection('kn5auf', file = '~/Desktop/test.csv')
}
}

0 comments on commit 5c8daf4

Please sign in to comment.