This commit is contained in:
+24
-24
@@ -1,24 +1,24 @@
|
|||||||
Package: civilytics
|
Package: civilytics
|
||||||
Type: Package
|
Type: Package
|
||||||
Title: Utilities Functions for Civilytics
|
Title: Utilities Functions for Civilytics
|
||||||
Version: 0.1.0
|
Version: 0.1.0
|
||||||
Author: Jared E. Knowles <jared@civilytics.com>
|
Author: Jared E. Knowles <jared@civilytics.com>
|
||||||
Maintainer: Jared E. Knowles <jared@civilytics.com>
|
Maintainer: Jared E. Knowles <jared@civilytics.com>
|
||||||
Description: House R functions for Civilytics Consulting LLC
|
Description: House R functions for Civilytics Consulting LLC
|
||||||
This package implements a variety of useful functions for creating and
|
This package implements a variety of useful functions for creating and
|
||||||
branding analyses produced by Civilytics Consulting LLC.
|
branding analyses produced by Civilytics Consulting LLC.
|
||||||
License: LICENSE
|
License: LICENSE
|
||||||
Depends:
|
Depends:
|
||||||
R (>= 2.15.1)
|
R (>= 2.15.1)
|
||||||
Imports:
|
Imports:
|
||||||
ggplot2,
|
ggplot2,
|
||||||
jpeg,
|
jpeg,
|
||||||
png,
|
png,
|
||||||
stringr,
|
stringr,
|
||||||
gridExtra,
|
gridExtra,
|
||||||
grid
|
grid
|
||||||
Encoding: UTF-8
|
Encoding: UTF-8
|
||||||
LazyData: true
|
LazyData: true
|
||||||
Suggests:
|
Suggests:
|
||||||
testthat
|
testthat
|
||||||
RoxygenNote: 7.1.1
|
RoxygenNote: 7.2.1
|
||||||
|
|||||||
@@ -12,9 +12,6 @@ add_logo(plot, logo, margin_param = NULL)
|
|||||||
\item{logo}{a logo grob created by make_logo_grob()}
|
\item{logo}{a logo grob created by make_logo_grob()}
|
||||||
|
|
||||||
\item{margin_param}{a numeric specifying what margin to add or subtract to align the logo}
|
\item{margin_param}{a numeric specifying what margin to add or subtract to align the logo}
|
||||||
}
|
|
||||||
\value{
|
|
||||||
|
|
||||||
}
|
}
|
||||||
\description{
|
\description{
|
||||||
Add a logo to a ggplot2 object
|
Add a logo to a ggplot2 object
|
||||||
|
|||||||
@@ -16,9 +16,6 @@ add_logo_ga(plot_list, logo, nrow = 1, widths = NULL, margin_param = NULL)
|
|||||||
\item{widths}{an optional vector the same length as plot_list with the widths for each plot}
|
\item{widths}{an optional vector the same length as plot_list with the widths for each plot}
|
||||||
|
|
||||||
\item{margin_param}{a number giving the adjustment up or down to help manually align logo and captions}
|
\item{margin_param}{a number giving the adjustment up or down to help manually align logo and captions}
|
||||||
}
|
|
||||||
\value{
|
|
||||||
|
|
||||||
}
|
}
|
||||||
\description{
|
\description{
|
||||||
Add a logo to a ggplot2 object
|
Add a logo to a ggplot2 object
|
||||||
|
|||||||
@@ -8,9 +8,6 @@ countDots(x)
|
|||||||
}
|
}
|
||||||
\arguments{
|
\arguments{
|
||||||
\item{x}{a character vector}
|
\item{x}{a character vector}
|
||||||
}
|
|
||||||
\value{
|
|
||||||
|
|
||||||
}
|
}
|
||||||
\description{
|
\description{
|
||||||
Count the number of single period entries in a vector
|
Count the number of single period entries in a vector
|
||||||
|
|||||||
@@ -8,13 +8,7 @@ get_png(filename)
|
|||||||
}
|
}
|
||||||
\arguments{
|
\arguments{
|
||||||
\item{filename}{a character with file path to a png file}
|
\item{filename}{a character with file path to a png file}
|
||||||
}
|
|
||||||
\value{
|
|
||||||
|
|
||||||
}
|
}
|
||||||
\description{
|
\description{
|
||||||
Plot a PNG file as a rasterGrob for inclusion in ggplot2
|
Plot a PNG file as a rasterGrob for inclusion in ggplot2
|
||||||
}
|
}
|
||||||
\examples{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|||||||
@@ -8,9 +8,6 @@ grade_level_to_num(x)
|
|||||||
}
|
}
|
||||||
\arguments{
|
\arguments{
|
||||||
\item{x}{character description of grade levels from NCES style data}
|
\item{x}{character description of grade levels from NCES style data}
|
||||||
}
|
|
||||||
\value{
|
|
||||||
|
|
||||||
}
|
}
|
||||||
\description{
|
\description{
|
||||||
Recode grade level from character to numeric
|
Recode grade level from character to numeric
|
||||||
|
|||||||
@@ -17,6 +17,6 @@ the caption
|
|||||||
Measure a ggplot2 object caption
|
Measure a ggplot2 object caption
|
||||||
}
|
}
|
||||||
\examples{
|
\examples{
|
||||||
p1 <- qplot(mpg, wt, data = mtcars)
|
p1 <- ggplot2::qplot(mpg, wt, data = mtcars)
|
||||||
measure_caption(p1) # Should equal 1 since no caption is required
|
measure_caption(p1) # Should equal 1 since no caption is required
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,9 +8,6 @@ race_short_names(x)
|
|||||||
}
|
}
|
||||||
\arguments{
|
\arguments{
|
||||||
\item{x}{a character vector with NCES race codes, often from Urban Institute}
|
\item{x}{a character vector with NCES race codes, often from Urban Institute}
|
||||||
}
|
|
||||||
\value{
|
|
||||||
|
|
||||||
}
|
}
|
||||||
\description{
|
\description{
|
||||||
Recode NCES race categories to shorter names
|
Recode NCES race categories to shorter names
|
||||||
|
|||||||
Reference in New Issue
Block a user