mirror of
https://github.com/agdamsbo/prioritized.grouping.git
synced 2026-06-19 05:47:30 +02:00
all build notes and errors handled
This commit is contained in:
parent
9606f4527d
commit
ea768fbba1
13 changed files with 195 additions and 476 deletions
|
|
@ -6,7 +6,7 @@
|
|||
\usage{
|
||||
grouping_plot(
|
||||
data,
|
||||
columns = NULL,
|
||||
columns = 4,
|
||||
overall = FALSE,
|
||||
viridis.option = "D",
|
||||
viridis.direction = -1
|
||||
|
|
@ -16,7 +16,7 @@ grouping_plot(
|
|||
\item{data}{A "prioritized_groups_list" class list from
|
||||
'prioritized_grouping()'}
|
||||
|
||||
\item{columns}{number of columns in plot}
|
||||
\item{columns}{number of columns in plot. Default=4.}
|
||||
|
||||
\item{overall}{logical to only print overall groups mean priority/cost}
|
||||
|
||||
|
|
@ -39,4 +39,7 @@ in the group.
|
|||
#read.csv(here::here("data/prioritized_sample.csv")) |>
|
||||
# prioritized_grouping(cap_classes = sample(4:12, 17, TRUE)) |>
|
||||
# grouping_plot()
|
||||
data.frame(id=paste0("id",1:100),
|
||||
matrix(replicate(100,sample(c(1:5,rep(NA,15)),10)),ncol=10,byrow = TRUE)) |>
|
||||
prioritized_grouping() |> grouping_plot(overall=TRUE)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,10 +4,10 @@
|
|||
\alias{plot.prioritized_groups_list}
|
||||
\title{Plot extension for easy groupings plot}
|
||||
\usage{
|
||||
\method{plot}{prioritized_groups_list}(data, ...)
|
||||
\method{plot}{prioritized_groups_list}(x, ...)
|
||||
}
|
||||
\arguments{
|
||||
\item{data}{data of class 'prioritized_groups_list'}
|
||||
\item{x}{data of class 'prioritized_groups_list'}
|
||||
|
||||
\item{...}{passed on to 'grouping_plot()'}
|
||||
}
|
||||
|
|
@ -18,7 +18,8 @@ ggplot2 list object
|
|||
Plot extension for easy groupings plot
|
||||
}
|
||||
\examples{
|
||||
read.csv(here::here("data/prioritized_sample.csv")) |>
|
||||
prioritized_grouping() |>
|
||||
plot(overall = TRUE, viridis.option="D",viridis.direction=-1)
|
||||
# read.csv(here::here("data/prioritized_sample.csv")) |>
|
||||
# prioritized_grouping() |>
|
||||
# plot(overall = TRUE, viridis.option="D",viridis.direction=-1)
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -34,7 +34,10 @@ list of custom class 'prioritized_groups_list'
|
|||
Solve grouping based on priorities or costs.
|
||||
}
|
||||
\examples{
|
||||
prioritized_grouping(
|
||||
data=read.csv(here::here("data/prioritized_sample.csv")),
|
||||
pre_grouped=read.csv(here::here("data/pre_grouped.csv"))) |> plot()
|
||||
# prioritized_grouping(
|
||||
# data=read.csv(here::here("data/prioritized_sample.csv")),
|
||||
# pre_grouped=read.csv(here::here("data/pre_grouped.csv"))) |> plot()
|
||||
data.frame(id=paste0("id",1:100),
|
||||
matrix(replicate(100,sample(c(1:5,rep(NA,15)),10)),ncol=10,byrow = TRUE)) |>
|
||||
prioritized_grouping()
|
||||
}
|
||||
|
|
|
|||
22
man/read_input.Rd
Normal file
22
man/read_input.Rd
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
% Generated by roxygen2: do not edit by hand
|
||||
% Please edit documentation in R/prioritized_grouping.R
|
||||
\name{read_input}
|
||||
\alias{read_input}
|
||||
\title{Flexible file import based on extension}
|
||||
\usage{
|
||||
read_input(file, consider.na = c("NA", "\\"\\"", ""))
|
||||
}
|
||||
\arguments{
|
||||
\item{file}{file name}
|
||||
|
||||
\item{consider.na}{character vector of strings to consider as NAs}
|
||||
}
|
||||
\value{
|
||||
tibble
|
||||
}
|
||||
\description{
|
||||
Flexible file import based on extension
|
||||
}
|
||||
\examples{
|
||||
read_input("https://raw.githubusercontent.com/agdamsbo/cognitive.index.lookup/main/data/sample.csv")
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue