content large_stringlengths 0 6.46M | path large_stringlengths 3 331 | license_type large_stringclasses 2
values | repo_name large_stringlengths 5 125 | language large_stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 4 6.46M | extension large_stringclasses 75
values | text stringlengths 0 6.46M |
|---|---|---|---|---|---|---|---|---|---|
library(tidyverse)
library(dslabs)
data(heights)
heights%>%ggplot(aes(height,fill = sex))+
geom_density(alpha = 0.5)
| /code.R | no_license | martinsdata/homework-0 | R | false | false | 120 | r | library(tidyverse)
library(dslabs)
data(heights)
heights%>%ggplot(aes(height,fill = sex))+
geom_density(alpha = 0.5)
|
testlist <- list(b = c(-1667457875L, -1935893348L, 67964173L, 67964173L, -1835887972L))
result <- do.call(mcga:::ByteVectorToDoubles,testlist)
str(result) | /mcga/inst/testfiles/ByteVectorToDoubles/AFL_ByteVectorToDoubles/ByteVectorToDoubles_valgrind_files/1613106043-test.R | no_license | akhikolla/updatedatatype-list3 | R | false | false | 155 | r | testlist <- list(b = c(-1667457875L, -1935893348L, 67964173L, 67964173L, -1835887972L))
result <- do.call(mcga:::ByteVectorToDoubles,testlist)
str(result) |
context("Test: organismAttributes()")
equal_lists <- function(df1, df2) {
isTRUE(all.equal(df1, df2))
}
test_that("The organismAttributes() interface works properly..",{
skip_on_cran()
oattr <- organismAttributes("Homo sapiens")
expect_identical(as.character(oattr[1,... | /tests/testthat/test-organismAttributes.R | no_license | NanaAkwasiAbayieBoateng/biomartr | R | false | false | 347 | r | context("Test: organismAttributes()")
equal_lists <- function(df1, df2) {
isTRUE(all.equal(df1, df2))
}
test_that("The organismAttributes() interface works properly..",{
skip_on_cran()
oattr <- organismAttributes("Homo sapiens")
expect_identical(as.character(oattr[1,... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/data.R
\docType{data}
\name{swe}
\alias{swe}
\title{Snow Water Equivalent}
\format{An object of data.frame class with 366 records and the following variables:
\describe{
\item{MonthDay}{month and day, with a required date format of \cod... | /man/swe.Rd | permissive | AllanWylie/WoodFiles | R | false | true | 1,029 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/data.R
\docType{data}
\name{swe}
\alias{swe}
\title{Snow Water Equivalent}
\format{An object of data.frame class with 366 records and the following variables:
\describe{
\item{MonthDay}{month and day, with a required date format of \cod... |
## download zip file
temp <- tempfile()
download.file("https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip",temp)
dateDownloaded <- date()
## unzip data
unzip(temp)
table.df <- read.table("household_power_consumption.txt", sep=";", na.strings="?", skip=66637, nrows=2880)
headers <- re... | /plot2.R | no_license | mevorama/Exploratory1 | R | false | false | 708 | r | ## download zip file
temp <- tempfile()
download.file("https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip",temp)
dateDownloaded <- date()
## unzip data
unzip(temp)
table.df <- read.table("household_power_consumption.txt", sep=";", na.strings="?", skip=66637, nrows=2880)
headers <- re... |
library(testthat)
library(BioSSA)
test_check("BioSSA")
| /tests/testthat.R | no_license | BioSSA/BioSSA | R | false | false | 56 | r | library(testthat)
library(BioSSA)
test_check("BioSSA")
|
TurnoversHome <- function(x,y)
{
turnover <- rep(0,nrow(y))
badpass <- rep(0,nrow(y))
traveling <- rep(0,nrow(y))
match <- data.frame(y,turnover,badpass,traveling)
D <- subset(x[c("h1","h2","h3","h4","h5","period","etype","player","reason")])
for (i in 1:nrow(D))
{
if (D[i,7]=="turnover")
{
j <- which(a... | /Turnover/turnoversHome.R | no_license | victorvicpal/FuncionesR | R | false | false | 695 | r | TurnoversHome <- function(x,y)
{
turnover <- rep(0,nrow(y))
badpass <- rep(0,nrow(y))
traveling <- rep(0,nrow(y))
match <- data.frame(y,turnover,badpass,traveling)
D <- subset(x[c("h1","h2","h3","h4","h5","period","etype","player","reason")])
for (i in 1:nrow(D))
{
if (D[i,7]=="turnover")
{
j <- which(a... |
# MEAN, MEDIAN & MODE
x = c(1,2,2,3,3,4,7,18,20,7,7)
# Finding mean for the vector
mean_x = mean(x)
print(mean_x)
#trim = 0.2 -> arranges elements in vector in ascending order
#removes 20% of elements from the start and the end of the vector
trim_mean_x = mean(x, trim = 0.2)
print(trim_mean_x)
# Finding ... | /Statistics-Basics.R | no_license | fnplus/Data-Visualizations-and-ML-Algorithms-using-R | R | false | false | 4,886 | r | # MEAN, MEDIAN & MODE
x = c(1,2,2,3,3,4,7,18,20,7,7)
# Finding mean for the vector
mean_x = mean(x)
print(mean_x)
#trim = 0.2 -> arranges elements in vector in ascending order
#removes 20% of elements from the start and the end of the vector
trim_mean_x = mean(x, trim = 0.2)
print(trim_mean_x)
# Finding ... |
library(ape)
testtree <- read.tree("12833_0.txt")
unrooted_tr <- unroot(testtree)
write.tree(unrooted_tr, file="12833_0_unrooted.txt") | /codeml_files/newick_trees_processed/12833_0/rinput.R | no_license | DaniBoo/cyanobacteria_project | R | false | false | 137 | r | library(ape)
testtree <- read.tree("12833_0.txt")
unrooted_tr <- unroot(testtree)
write.tree(unrooted_tr, file="12833_0_unrooted.txt") |
## Downloading and unzipping file
if (!file.exists("household_power_consumption.txt")) {
url <-
"https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip"
download.file(url, "household_pw_cons.zip", "curl")
unzip("household_pw_cons.zip")
}
## Reading file into data frame... | /plot3.R | no_license | Lluis73/ExData_Plotting1 | R | false | false | 1,456 | r | ## Downloading and unzipping file
if (!file.exists("household_power_consumption.txt")) {
url <-
"https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip"
download.file(url, "household_pw_cons.zip", "curl")
unzip("household_pw_cons.zip")
}
## Reading file into data frame... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/cl_get_api_call.r
\name{cl_get_api_call}
\alias{cl_get_api_call}
\title{cl_get_api_call}
\usage{
cl_get_api_call(url, endpoint, auth)
}
\arguments{
\item{url}{URL of the concept library application}
\item{auth}{A crul::auth object... | /ConceptLibraryClient/man/cl_get_api_call.Rd | no_license | DSThayer/concept-library-client | R | false | true | 687 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/cl_get_api_call.r
\name{cl_get_api_call}
\alias{cl_get_api_call}
\title{cl_get_api_call}
\usage{
cl_get_api_call(url, endpoint, auth)
}
\arguments{
\item{url}{URL of the concept library application}
\item{auth}{A crul::auth object... |
require("pracma")
alpha=1
w=runif(25,min=0,max=5)*0 #random initial values for oscillators
G <- make_lattice( c(5,5) )
G=graph.adjacency(A,mode=c("directed"))
elos=get.edgelist(G)
N=length(V(G))
x=matrix(runif(N),ncol=1,nrow=N)*5
t=0
... | /kuramoto.r | no_license | tischieber/Diffusion-Capacity-of-Single-and-Interconnected-Networks | R | false | false | 1,601 | r |
require("pracma")
alpha=1
w=runif(25,min=0,max=5)*0 #random initial values for oscillators
G <- make_lattice( c(5,5) )
G=graph.adjacency(A,mode=c("directed"))
elos=get.edgelist(G)
N=length(V(G))
x=matrix(runif(N),ncol=1,nrow=N)*5
t=0
... |
get.numalts <-
function(pctil,null.mean,null.sd,null.prop,vals,up = TRUE){
cutoff.val = qnorm(pctil,null.mean,null.sd)
num.nulls = null.prop*length(vals)
# I use "above" to mean "above or below". very loose...
coef1 = ifelse(up,1-pctil,pctil)
num.nulls.above = coef1*num.nulls
num.total.above = ifelse(up,sum(vals>... | /Rpackage-21Aug/tornado/R/get.numalts.R | no_license | Libardo1/tornado | R | false | false | 548 | r | get.numalts <-
function(pctil,null.mean,null.sd,null.prop,vals,up = TRUE){
cutoff.val = qnorm(pctil,null.mean,null.sd)
num.nulls = null.prop*length(vals)
# I use "above" to mean "above or below". very loose...
coef1 = ifelse(up,1-pctil,pctil)
num.nulls.above = coef1*num.nulls
num.total.above = ifelse(up,sum(vals>... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/phyloSignal.R
\name{lambdaTest}
\alias{lambdaTest}
\title{Test Pagel's Lambda
Optimize Pagel's Lambda and do a likelihood ratio test.}
\usage{
lambdaTest(x, vcv)
}
\arguments{
\item{x}{a vector of numeric data.}
\item{vcv}{the phylogenetic v... | /man/lambdaTest.Rd | no_license | fkeck/phylosignal | R | false | true | 581 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/phyloSignal.R
\name{lambdaTest}
\alias{lambdaTest}
\title{Test Pagel's Lambda
Optimize Pagel's Lambda and do a likelihood ratio test.}
\usage{
lambdaTest(x, vcv)
}
\arguments{
\item{x}{a vector of numeric data.}
\item{vcv}{the phylogenetic v... |
## Homework 2 / Problem 1
## Problem description:
## https://firebasestorage.googleapis.com/v0/b/uni-sofia.appspot.com/o/homeworks%2FHomework_2.pdf?alt=media
## Install the following packages if necessary. Uncomment the following line and execute it.
## install.packages(c('dplyr', 'ggplot2'))
## Load packages
librar... | /Problem_1.R | no_license | sibelkodzhaa/hw-econometrics2018-en-h2 | R | false | false | 2,663 | r | ## Homework 2 / Problem 1
## Problem description:
## https://firebasestorage.googleapis.com/v0/b/uni-sofia.appspot.com/o/homeworks%2FHomework_2.pdf?alt=media
## Install the following packages if necessary. Uncomment the following line and execute it.
## install.packages(c('dplyr', 'ggplot2'))
## Load packages
librar... |
library(gpuR)
context("CPU vclVector Utility Functions")
set.seed(123)
ORDER <- 100
A <- sample(seq.int(10), ORDER, replace = TRUE)
D <- rnorm(ORDER)
D2 <- rnorm(ORDER)
test_that("integer vclVector length method successful", {
has_cpu_skip()
gpuA <- vclVector(A)
s <- length(gpuA)
e... | /tests/testthat/test_cpu_vclVector_utils.R | no_license | bryant1410/gpuR | R | false | false | 4,448 | r | library(gpuR)
context("CPU vclVector Utility Functions")
set.seed(123)
ORDER <- 100
A <- sample(seq.int(10), ORDER, replace = TRUE)
D <- rnorm(ORDER)
D2 <- rnorm(ORDER)
test_that("integer vclVector length method successful", {
has_cpu_skip()
gpuA <- vclVector(A)
s <- length(gpuA)
e... |
# context("check the align_fastq_to_vdjca function")
# align_fastq_to_vdjca ----
# test_that("align_fastq_to_vdjca gives correct command to console with R1_R2", {
# expect_equal(
# align_fastq_to_vdjca(
# java_param = "java -Xmx4g -Xms3g -jar",
# path_mixcr = "D:/Maria/Maria_Analysis/mixcr-2.1.7/mix... | /tests/testthat/test_align_fastq.R | no_license | debdagybra/IMIabgd | R | false | false | 3,283 | r |
# context("check the align_fastq_to_vdjca function")
# align_fastq_to_vdjca ----
# test_that("align_fastq_to_vdjca gives correct command to console with R1_R2", {
# expect_equal(
# align_fastq_to_vdjca(
# java_param = "java -Xmx4g -Xms3g -jar",
# path_mixcr = "D:/Maria/Maria_Analysis/mixcr-2.1.7/mix... |
# summary, aggregate 요약, 총계 패키지 설명
mtcars
install.packages("MASS")
library(MASS)
data(Aids2)
?Aids2
head(Aids2)
# 요약 / 카테고리별 수/넘버요약
summary(Aids2)
# 0세 데이터 뽑아보기
Aids2[which(Aids2$age==0),]
# alive people
Alive=Aids2[which(Aids2$status=="A"),]
Dead <- Aids2[which(Aids2$status=="D"),]
# aggregate(궁금한 것, by=기준, 값)
ag... | /inflearn_lecture/lec 1-23 [Summary&aggregate].R | permissive | cutz-j/R-Programming | R | false | false | 605 | r | # summary, aggregate 요약, 총계 패키지 설명
mtcars
install.packages("MASS")
library(MASS)
data(Aids2)
?Aids2
head(Aids2)
# 요약 / 카테고리별 수/넘버요약
summary(Aids2)
# 0세 데이터 뽑아보기
Aids2[which(Aids2$age==0),]
# alive people
Alive=Aids2[which(Aids2$status=="A"),]
Dead <- Aids2[which(Aids2$status=="D"),]
# aggregate(궁금한 것, by=기준, 값)
ag... |
retrieveKGML.new <- function (pathway, organism, destfile, method = "auto", ...)
{
kgml <- paste0("http://rest.kegg.jp/get/",pathway,"/kgml")
download.file(kgml, destfile = destfile, method = method,
...)
return(invisible(kgml))
}
| /R/retrieveKGML.new.R | permissive | uc-bd2k/paslincs | R | false | false | 251 | r | retrieveKGML.new <- function (pathway, organism, destfile, method = "auto", ...)
{
kgml <- paste0("http://rest.kegg.jp/get/",pathway,"/kgml")
download.file(kgml, destfile = destfile, method = method,
...)
return(invisible(kgml))
}
|
suppressPackageStartupMessages(library(coloc))
suppressPackageStartupMessages(library(dplyr))
"%&%" = function(a,b) paste(a,b,sep="")
check.fread<-function(file,header=T,stringsAsFactors=F){
#Author Ryan Schubert
#Meant to be run in unix environments with the zcat program installed
#Not for the R environ, but u... | /old/05_coloc.R | no_license | egeoffroy/LD_matrix_build | R | false | false | 16,896 | r | suppressPackageStartupMessages(library(coloc))
suppressPackageStartupMessages(library(dplyr))
"%&%" = function(a,b) paste(a,b,sep="")
check.fread<-function(file,header=T,stringsAsFactors=F){
#Author Ryan Schubert
#Meant to be run in unix environments with the zcat program installed
#Not for the R environ, but u... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/map.R
\name{map}
\alias{map}
\title{Map flood extents from processed data}
\usage{
map(name.dir, write = TRUE, add = 0)
}
\arguments{
\item{name.dir}{the directory where processed data is stored}
\item{write}{logical. Should output rasters b... | /man/map.Rd | permissive | keyao22/FloodMapping | R | false | true | 613 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/map.R
\name{map}
\alias{map}
\title{Map flood extents from processed data}
\usage{
map(name.dir, write = TRUE, add = 0)
}
\arguments{
\item{name.dir}{the directory where processed data is stored}
\item{write}{logical. Should output rasters b... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/euclidean.R
\name{euclidean}
\alias{euclidean}
\title{euclidean}
\usage{
euclidean(x, y)
}
\arguments{
\item{x}{A numeric input.}
\item{y}{A numeric input.}
}
\value{
The Euclidean of \code{x} and \code{y}.
}
\description{
\url{https://en.wi... | /man/euclidean.Rd | no_license | OLGJ/easyalgorithms | R | false | true | 360 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/euclidean.R
\name{euclidean}
\alias{euclidean}
\title{euclidean}
\usage{
euclidean(x, y)
}
\arguments{
\item{x}{A numeric input.}
\item{y}{A numeric input.}
}
\value{
The Euclidean of \code{x} and \code{y}.
}
\description{
\url{https://en.wi... |
#' Generate one string from a list of strings
#'
#' @param args named list of arguments
#' @param argNames boolean indicating whether argument names should be included in the final output.
#' @param sep a character to separate arguments and their names. Defaults to ":".
#' @param collapse a character to separate argume... | /R/cacheCall.R | no_license | jlaffy/cacheCall | R | false | false | 3,492 | r | #' Generate one string from a list of strings
#'
#' @param args named list of arguments
#' @param argNames boolean indicating whether argument names should be included in the final output.
#' @param sep a character to separate arguments and their names. Defaults to ":".
#' @param collapse a character to separate argume... |
\name{pc}
\alias{pc}
\title{PC ("Peter/Clark") algorithm}
\description{
\code{pc} is the PC ("Peter/Clark") algorithm.
}
\usage{
pc(df, continuous = TRUE, depth = 3, aggressivelyPreventCycles = FALSE,
falseDiscoveryRate = FALSE, significance = 0.05,
verbose = FALSE, java.parameters = NULL, priorKnowledge = NULL)... | /man/pc.Rd | no_license | regenworm/r-causal | R | false | false | 2,482 | rd | \name{pc}
\alias{pc}
\title{PC ("Peter/Clark") algorithm}
\description{
\code{pc} is the PC ("Peter/Clark") algorithm.
}
\usage{
pc(df, continuous = TRUE, depth = 3, aggressivelyPreventCycles = FALSE,
falseDiscoveryRate = FALSE, significance = 0.05,
verbose = FALSE, java.parameters = NULL, priorKnowledge = NULL)... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/plots.R
\name{scatter.thinning}
\alias{scatter.thinning}
\title{Remove points from a scatter plot where density is really high}
\usage{
scatter.thinning(x, y, resolution = 100, max.per.cell = 100)
}
\arguments{
\item{x}{x-coordinates vector}
... | /man/scatter.thinning.Rd | permissive | thomasbattram/usefunc | R | false | true | 691 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/plots.R
\name{scatter.thinning}
\alias{scatter.thinning}
\title{Remove points from a scatter plot where density is really high}
\usage{
scatter.thinning(x, y, resolution = 100, max.per.cell = 100)
}
\arguments{
\item{x}{x-coordinates vector}
... |
context("CD_path")
# set up input variable
data_matrix <- matrix(c(1, 1, 0, 0, 1, 1,
1, 1, 0, 1, 1, 1,
0, 0, 1, 0, 0, 1,
0, 0, 1, 0, 0, 1,
0, 0, 0, 1, 1, 0,
0, 0, 0, 1, 1, 1,
... | /fuzzedpackages/discretecdAlgorithm/tests/testthat/test-CD_path.R | no_license | akhikolla/testpackages | R | false | false | 14,837 | r | context("CD_path")
# set up input variable
data_matrix <- matrix(c(1, 1, 0, 0, 1, 1,
1, 1, 0, 1, 1, 1,
0, 0, 1, 0, 0, 1,
0, 0, 1, 0, 0, 1,
0, 0, 0, 1, 1, 0,
0, 0, 0, 1, 1, 1,
... |
#' @title extrema.irr
#' @aliases extrema.irr
#' @author Pierre Roudier
#' @description Finds regional extrema on a irregularly sampled data set
#' @include create_neig.r
extrema.irr <- function(
data.set,
gridded.data,
neig = NULL,
zcol = 'z',
duplicate = 'remove',
nb.nn = 4, # Number of nearest neighbour... | /inDev/extrema_irr-optim2.r | no_license | juejack/spemd | R | false | false | 2,243 | r | #' @title extrema.irr
#' @aliases extrema.irr
#' @author Pierre Roudier
#' @description Finds regional extrema on a irregularly sampled data set
#' @include create_neig.r
extrema.irr <- function(
data.set,
gridded.data,
neig = NULL,
zcol = 'z',
duplicate = 'remove',
nb.nn = 4, # Number of nearest neighbour... |
library(ape)
testtree <- read.tree("4968_7.txt")
unrooted_tr <- unroot(testtree)
write.tree(unrooted_tr, file="4968_7_unrooted.txt") | /codeml_files/newick_trees_processed/4968_7/rinput.R | no_license | DaniBoo/cyanobacteria_project | R | false | false | 135 | r | library(ape)
testtree <- read.tree("4968_7.txt")
unrooted_tr <- unroot(testtree)
write.tree(unrooted_tr, file="4968_7_unrooted.txt") |
library(shiny)
zoom = FALSE
ui <- fluidPage(
titlePanel("Hello Cardiff"),
sidebarLayout(
sidebarPanel(
uiOutput("sidebarui"),
# (part 1) place for actionButton
actionButton("go_button", "Go!"),
# (part 2) place for textInput
textInput("name", "Give your name here")
),
mai... | /ex4_sol.R | no_license | CaRdiffR/shiny-workshop | R | false | false | 1,113 | r | library(shiny)
zoom = FALSE
ui <- fluidPage(
titlePanel("Hello Cardiff"),
sidebarLayout(
sidebarPanel(
uiOutput("sidebarui"),
# (part 1) place for actionButton
actionButton("go_button", "Go!"),
# (part 2) place for textInput
textInput("name", "Give your name here")
),
mai... |
library(qcr)
### Name: npqcs.S
### Title: Function to plot the S chart
### Aliases: npqcs.S npqcs.S.default npqcs.S.npqcd
### ** Examples
## Not run:
##D ##
##D ## Continuous data
##D ##
##D set.seed(12345)
##D mu<-c(0,0)
##D Sigma<- matrix(c(1,0,0,1),nrow = 2,ncol = 2)
##D u <- c(2,2)
##D S <- matrix(c(4,0,0,4)... | /data/genthat_extracted_code/qcr/examples/npqcs.S.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 659 | r | library(qcr)
### Name: npqcs.S
### Title: Function to plot the S chart
### Aliases: npqcs.S npqcs.S.default npqcs.S.npqcd
### ** Examples
## Not run:
##D ##
##D ## Continuous data
##D ##
##D set.seed(12345)
##D mu<-c(0,0)
##D Sigma<- matrix(c(1,0,0,1),nrow = 2,ncol = 2)
##D u <- c(2,2)
##D S <- matrix(c(4,0,0,4)... |
#6 - Em um levantamento realizado em um hospital, 95 pessoas responderam a seguinte
#questão: Como você classifica o atendimento recebido? As possíveis respostas estavam
#classificadas em Péssimo, Ruim, Razoável, Bom ou Excelente. O número de pessoas em
#cada uma dessas classes pode ser encontrado na tabela (os dados e... | /codigo/exercicio6.R | no_license | winea/TrabalhoEstatisticaWinea | R | false | false | 1,068 | r | #6 - Em um levantamento realizado em um hospital, 95 pessoas responderam a seguinte
#questão: Como você classifica o atendimento recebido? As possíveis respostas estavam
#classificadas em Péssimo, Ruim, Razoável, Bom ou Excelente. O número de pessoas em
#cada uma dessas classes pode ser encontrado na tabela (os dados e... |
## Put comments here that give an overall description of what your
## functions do
## Write a short comment describing this function
makeCacheMatrix <- function(x = matrix()) {
m <- NULL
set <- function(y) {
x <<- y
m <<- NULL
}
get <- function() x
setsolve<-function(solve) m<<-solve
... | /cachematrix.R | no_license | Alan112222/ProgrammingAssignment2 | R | false | false | 728 | r | ## Put comments here that give an overall description of what your
## functions do
## Write a short comment describing this function
makeCacheMatrix <- function(x = matrix()) {
m <- NULL
set <- function(y) {
x <<- y
m <<- NULL
}
get <- function() x
setsolve<-function(solve) m<<-solve
... |
#' @include deviceManager.R
NULL
#' Compute and draw clustering results
#'
#' This function is able to compute clustering and plot the results on a widget or in a file. It uses
#' euclidean distances and the Ward method. Supported file formats are .svg and .tiff. If another extension is detected, then the
#' function ... | /R/clustering.R | no_license | Neki/ProjetEnjeuSBT | R | false | false | 1,664 | r | #' @include deviceManager.R
NULL
#' Compute and draw clustering results
#'
#' This function is able to compute clustering and plot the results on a widget or in a file. It uses
#' euclidean distances and the Ward method. Supported file formats are .svg and .tiff. If another extension is detected, then the
#' function ... |
library(ape)
testtree <- read.tree("6581_0.txt")
unrooted_tr <- unroot(testtree)
write.tree(unrooted_tr, file="6581_0_unrooted.txt") | /codeml_files/newick_trees_processed/6581_0/rinput.R | no_license | DaniBoo/cyanobacteria_project | R | false | false | 135 | r | library(ape)
testtree <- read.tree("6581_0.txt")
unrooted_tr <- unroot(testtree)
write.tree(unrooted_tr, file="6581_0_unrooted.txt") |
library(dplyr)
library(tidyr)
library(ggplot2)
library(AirportPassengerFlow)
set.seed(1)
flight_level_disembark
gate_level
nat_level
route_level
observations_w_10
global_level_1 <- global_fun_1(walk_alpha = 1.5, walk_beta = 3)
sigma_k <- 20
inp <- list(global_level_1 = global_level_1, flight_level = flight_level_... | /script/abcpy.R | no_license | ritiktaneja/DynamicQueueNetwork | R | false | false | 972 | r |
library(dplyr)
library(tidyr)
library(ggplot2)
library(AirportPassengerFlow)
set.seed(1)
flight_level_disembark
gate_level
nat_level
route_level
observations_w_10
global_level_1 <- global_fun_1(walk_alpha = 1.5, walk_beta = 3)
sigma_k <- 20
inp <- list(global_level_1 = global_level_1, flight_level = flight_level_... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/backupgateway_operations.R
\name{backupgateway_tag_resource}
\alias{backupgateway_tag_resource}
\title{Tag the resource}
\usage{
backupgateway_tag_resource(ResourceARN, Tags)
}
\arguments{
\item{ResourceARN}{[required] The Amazon Resource Nam... | /cran/paws.networking/man/backupgateway_tag_resource.Rd | permissive | paws-r/paws | R | false | true | 570 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/backupgateway_operations.R
\name{backupgateway_tag_resource}
\alias{backupgateway_tag_resource}
\title{Tag the resource}
\usage{
backupgateway_tag_resource(ResourceARN, Tags)
}
\arguments{
\item{ResourceARN}{[required] The Amazon Resource Nam... |
#' oblicza proste zmienne niezwiazane z okienkami czasu
#' @param dane dane wygenerowane za pomocą funkcji \code{\link{polacz_zus_zdau}}
#' @param zdau dane wygenerowane za pomocą funkcji \code{\link{przygotuj_zdau}}
#' @return data.frame wyliczone zmienne
#' @export
#' @import dplyr
oblicz_stale = function(dane, zdau)... | /R/oblicz_stale.R | no_license | zozlak/MLAKdane | R | false | false | 3,092 | r | #' oblicza proste zmienne niezwiazane z okienkami czasu
#' @param dane dane wygenerowane za pomocą funkcji \code{\link{polacz_zus_zdau}}
#' @param zdau dane wygenerowane za pomocą funkcji \code{\link{przygotuj_zdau}}
#' @return data.frame wyliczone zmienne
#' @export
#' @import dplyr
oblicz_stale = function(dane, zdau)... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/generated_client.R
\name{imports_post_syncs}
\alias{imports_post_syncs}
\title{Create a sync}
\usage{
imports_post_syncs(id, source, destination, advanced_options = NULL)
}
\arguments{
\item{id}{integer required.}
\item{source}{list required... | /man/imports_post_syncs.Rd | no_license | ajchin/civis-r | R | false | true | 6,031 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/generated_client.R
\name{imports_post_syncs}
\alias{imports_post_syncs}
\title{Create a sync}
\usage{
imports_post_syncs(id, source, destination, advanced_options = NULL)
}
\arguments{
\item{id}{integer required.}
\item{source}{list required... |
#Plot 1 is a histogram of Global Active Power (kilowatts) in red.
##Plot 1 has the title "Global Active Power"
## and only covers a two day period: 2007-02-01 and 2007-02-02.
#Point to data to be loaded.
datafile <- "household_power_consumption.txt"
#Load data.
data <- read.table(datafile,
header =... | /plot1.R | no_license | zank1776/ExData_Plotting1 | R | false | false | 847 | r | #Plot 1 is a histogram of Global Active Power (kilowatts) in red.
##Plot 1 has the title "Global Active Power"
## and only covers a two day period: 2007-02-01 and 2007-02-02.
#Point to data to be loaded.
datafile <- "household_power_consumption.txt"
#Load data.
data <- read.table(datafile,
header =... |
#DAY 3
#Mapping with Google
#AYESHA HARGEY
#3650393
#31 January 2019
#Homework: convert CSV to .Rdata. Write one line of code to do this.
#First load your CSV into R and then convert.
#Write a 5 line paragraph discussing the library ggsn and library scales. Description.
#Practice how to read code
# Load libraries
... | /Day_3_Mapping_with_Google.R | no_license | ahargey/Intro_R_UWC | R | false | false | 562 | r | #DAY 3
#Mapping with Google
#AYESHA HARGEY
#3650393
#31 January 2019
#Homework: convert CSV to .Rdata. Write one line of code to do this.
#First load your CSV into R and then convert.
#Write a 5 line paragraph discussing the library ggsn and library scales. Description.
#Practice how to read code
# Load libraries
... |
install.packages("swirl")
| /testScript.R | no_license | basnet10/datasciencecoursera | R | false | false | 26 | r | install.packages("swirl")
|
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/coxDKsplsDR.R, R/coxDKsplsDR.default.R,
% R/coxDKsplsDR.formula.R
\name{coxDKsplsDR}
\alias{coxDKsplsDR}
\alias{coxDKsplsDR.default}
\alias{coxDKsplsDR.formula}
\title{Fitting a Direct Kernel sPLSR model on the (Deviance) Residuals}
\usage{... | /man/coxDKsplsDR.Rd | no_license | cran/plsRcox | R | false | true | 9,614 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/coxDKsplsDR.R, R/coxDKsplsDR.default.R,
% R/coxDKsplsDR.formula.R
\name{coxDKsplsDR}
\alias{coxDKsplsDR}
\alias{coxDKsplsDR.default}
\alias{coxDKsplsDR.formula}
\title{Fitting a Direct Kernel sPLSR model on the (Deviance) Residuals}
\usage{... |
#' Sample dots from spatial polygons
#'
#' Sample dots from spatial polygons according to a spatial distribution of a population. The population may consist of classes. The output, a SpatialPointsDataFrame, can be used to create a dot map (see \code{\link{tm_dots}}), where the dots are colored according to the class... | /tmap/R/sample_dots.R | no_license | ingted/R-Examples | R | false | false | 9,207 | r | #' Sample dots from spatial polygons
#'
#' Sample dots from spatial polygons according to a spatial distribution of a population. The population may consist of classes. The output, a SpatialPointsDataFrame, can be used to create a dot map (see \code{\link{tm_dots}}), where the dots are colored according to the class... |
########################
#Clean the work station.
########################
rm(list = ls(all = T))
setwd("/home/saikiran/Desktop/Fall 2017/applied_stats_rachael/Homeworks/HW2")
######
#Q3
######
##################################################################################
#Generate 20 cols with 1000 numbers.
#Mos... | /Homeworks/HW2/HW2_3.R | no_license | saikiransunny/DataMining_supervised_fall | R | false | false | 8,387 | r | ########################
#Clean the work station.
########################
rm(list = ls(all = T))
setwd("/home/saikiran/Desktop/Fall 2017/applied_stats_rachael/Homeworks/HW2")
######
#Q3
######
##################################################################################
#Generate 20 cols with 1000 numbers.
#Mos... |
## Put comments here that give an overall description of what your
## functions do
## Write a short comment describing this function - this basically follows the same code as
## the example in programming assignment 3 with changes from "mean" to "inv
makeCacheMatrix <- function(x = matrix()) {
m = NULL # mak... | /cachematrix.R | no_license | meehanma98/ProgrammingAssignment2 | R | false | false | 1,950 | r | ## Put comments here that give an overall description of what your
## functions do
## Write a short comment describing this function - this basically follows the same code as
## the example in programming assignment 3 with changes from "mean" to "inv
makeCacheMatrix <- function(x = matrix()) {
m = NULL # mak... |
#' Linear regression models using an S3 class and the calculations are done using QR Decomposition
#'
#' @param formula formula
#' @param data a dataframe
#'
#' @return Returns an object of the class linreg
#' @export
#'
#' @examples linreg_mod <-linreg(Petal.Length~Sepal.Width+Sepal.Length, data=iris)
#' summary(li... | /lab4/R/linreg_s3.R | no_license | fengjuanchen/94lab4 | R | false | false | 3,517 | r |
#' Linear regression models using an S3 class and the calculations are done using QR Decomposition
#'
#' @param formula formula
#' @param data a dataframe
#'
#' @return Returns an object of the class linreg
#' @export
#'
#' @examples linreg_mod <-linreg(Petal.Length~Sepal.Width+Sepal.Length, data=iris)
#' summary(li... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/getAttributesColumnHeaders.R
\name{getAttributesColumnHeaders}
\alias{getAttributesColumnHeaders}
\title{getAttributesColumnHeaders - Gets the attribute column header for all or specified attributes in an entityType.
\code{getAttributesColumn... | /man/getAttributesColumnHeaders.Rd | no_license | AmundsenJunior/pfsrsdk | R | false | true | 1,575 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/getAttributesColumnHeaders.R
\name{getAttributesColumnHeaders}
\alias{getAttributesColumnHeaders}
\title{getAttributesColumnHeaders - Gets the attribute column header for all or specified attributes in an entityType.
\code{getAttributesColumn... |
# Copyright (C) 2019-2021 Victor Ordu.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is di... | /tests/testthat/test-regions.R | no_license | cran/naijR | R | false | false | 5,921 | r | # Copyright (C) 2019-2021 Victor Ordu.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is di... |
# plot4.R Creates multiple graphs on same PNG
# We assume data is placed in the working directory
# using first row as header
# Na string is '?'
Rdata <- read.table("household_power_consumption.txt", stringsAsFactors=FALSE,
header = TRUE, sep=';', na.strings = "?")
# Subsetting: using data from t... | /plot4.R | no_license | JeanFrancoisRoy/ExData_Plotting1 | R | false | false | 1,505 | r |
# plot4.R Creates multiple graphs on same PNG
# We assume data is placed in the working directory
# using first row as header
# Na string is '?'
Rdata <- read.table("household_power_consumption.txt", stringsAsFactors=FALSE,
header = TRUE, sep=';', na.strings = "?")
# Subsetting: using data from t... |
#' Set parameter ranges for ACPy
#'
#' Read ACPy xml configuration file and set ranges for the parameter
#'
#' @param acpyXML XML file used for ACPy calibration
#' @param param character corresponding to the name of the parameter in the ACPy xml file
#' @param min Minimum value for the parameter range
#' @param max Max... | /R/setRange.R | permissive | aemon-j/gotmtools | R | false | false | 874 | r | #' Set parameter ranges for ACPy
#'
#' Read ACPy xml configuration file and set ranges for the parameter
#'
#' @param acpyXML XML file used for ACPy calibration
#' @param param character corresponding to the name of the parameter in the ACPy xml file
#' @param min Minimum value for the parameter range
#' @param max Max... |
library(readr)
library(tidyr)
library(dplyr)
cons[[1]] <- read_tsv("kl2004 consensus.txt" ,col_names = TRUE) %>%
filter(map_name=="LG-01") %>%
select(c("feature_name","feature_aliases","feature_start")) %>%
#semi_join(all, by=c("feature_name"="all")) %>%
arrange("Mean")
cons[[2]] <- read_tsv("mac2010a consensu... | /Data/Genetic Maps/Consensus Maps/all_consensus.R | no_license | ahmedaquib/sorghum-meta-QTL | R | false | false | 1,613 | r | library(readr)
library(tidyr)
library(dplyr)
cons[[1]] <- read_tsv("kl2004 consensus.txt" ,col_names = TRUE) %>%
filter(map_name=="LG-01") %>%
select(c("feature_name","feature_aliases","feature_start")) %>%
#semi_join(all, by=c("feature_name"="all")) %>%
arrange("Mean")
cons[[2]] <- read_tsv("mac2010a consensu... |
## Slide 6
library(MASS)
head(cats)
## Slide 7
hist(cats$Hwt)
## Slide 8
quantile(cats$Hwt, c(0.25, 0.5, 0.75))
## Slide 10
plot(ecdf(cats$Hwt),
main = "Empirical CDF of Cat Heart Weights")
## Slide 12
hist(cats$Hwt, probability = TRUE, ylim = c(0, 0.17))
lines(density(cats$Hwt), lty = "dashed")
# C... | /lecture scripts/Set10_ISCDS_Full_R_Script.R | no_license | shyuwang/GR5206-stat_computing_and_intro_to_ds | R | false | false | 6,320 | r |
## Slide 6
library(MASS)
head(cats)
## Slide 7
hist(cats$Hwt)
## Slide 8
quantile(cats$Hwt, c(0.25, 0.5, 0.75))
## Slide 10
plot(ecdf(cats$Hwt),
main = "Empirical CDF of Cat Heart Weights")
## Slide 12
hist(cats$Hwt, probability = TRUE, ylim = c(0, 0.17))
lines(density(cats$Hwt), lty = "dashed")
# C... |
fileName <- "household_power_consumption.txt"
#sample first 100 rows
sample <- read.csv(fileName, sep = ";", nrows = 100, stringsAsFactors = FALSE)
#get classes from sample
classes <- sapply(sample, class)
#read file
fh<-file("household_power_consumption.txt","r");
data <- read.table(
... | /plot1.R | no_license | Hythlodaeus42/ExData_Plotting1 | R | false | false | 875 | r | fileName <- "household_power_consumption.txt"
#sample first 100 rows
sample <- read.csv(fileName, sep = ";", nrows = 100, stringsAsFactors = FALSE)
#get classes from sample
classes <- sapply(sample, class)
#read file
fh<-file("household_power_consumption.txt","r");
data <- read.table(
... |
mapAuthorToDOI <-
function(groups, markRelevant = FALSE, marking.symbol = '*') {
result = vector(mode="character", length = 0)
for(i in 1:length(groups)) {
authors = groups[[i]]
group = vector(mode="character", length = 0)
# Map Autor to DOI
for (y in 1:length(authors)) {
DOI = ''
if (!i... | /R/mapAuthorToDOI.R | no_license | mfinst/TM-CoCit-Support-FM | R | false | false | 1,112 | r | mapAuthorToDOI <-
function(groups, markRelevant = FALSE, marking.symbol = '*') {
result = vector(mode="character", length = 0)
for(i in 1:length(groups)) {
authors = groups[[i]]
group = vector(mode="character", length = 0)
# Map Autor to DOI
for (y in 1:length(authors)) {
DOI = ''
if (!i... |
fluidPage(
titlePanel("Correlations: Histograms"),
sidebarLayout(
sidebarPanel(
helpText("Generate histograms to vizualize how the distribution of the correlations is changing with age."),
selectInput("distance",
label = "Select the metric",
choices = bu... | /ShinyApp/uis/Correlations/Correlations_Histograms_ui.R | no_license | alanlegoallec/Biomarkers_Codependencies | R | false | false | 915 | r | fluidPage(
titlePanel("Correlations: Histograms"),
sidebarLayout(
sidebarPanel(
helpText("Generate histograms to vizualize how the distribution of the correlations is changing with age."),
selectInput("distance",
label = "Select the metric",
choices = bu... |
context("fit_em_range")
test_that("function exists", {
expect_is(fit_em_range, "function")
})
test_that("function estimates parameters via em", {
sampledata <- generate_sample(1000, 5)
expect_is(fit_em_range(sampledata, 5), "data.frame")
})
test_that("function fits different numbers of modes", {
sampledata <... | /tests/testthat/test-emfit_range.R | no_license | akimanabe/kongor2 | R | false | false | 765 | r | context("fit_em_range")
test_that("function exists", {
expect_is(fit_em_range, "function")
})
test_that("function estimates parameters via em", {
sampledata <- generate_sample(1000, 5)
expect_is(fit_em_range(sampledata, 5), "data.frame")
})
test_that("function fits different numbers of modes", {
sampledata <... |
#' Tuning the choice of q (number of clusters) before running spatialCluster
#'
#' Before running \code{spatialCluster()}, we recommend tuning the choice of
#' \code{q} by choosing the \code{q} that maximizes the model's negative log
#' likelihood over early iterations. \code{qTune()} computes the average
#' negative l... | /R/qTune.R | permissive | JunqiangWang/BayesSpace | R | false | false | 4,071 | r | #' Tuning the choice of q (number of clusters) before running spatialCluster
#'
#' Before running \code{spatialCluster()}, we recommend tuning the choice of
#' \code{q} by choosing the \code{q} that maximizes the model's negative log
#' likelihood over early iterations. \code{qTune()} computes the average
#' negative l... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/occCiteData.R
\docType{class}
\name{occCiteData-class}
\alias{occCiteData-class}
\alias{occCiteData}
\title{occCite Data Class}
\description{
A class for managing metadata associated with occCite queries and data manipulation.
}
\section{Slot... | /man/occCiteData-class.Rd | no_license | cmerow/occCite | R | false | true | 1,587 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/occCiteData.R
\docType{class}
\name{occCiteData-class}
\alias{occCiteData-class}
\alias{occCiteData}
\title{occCite Data Class}
\description{
A class for managing metadata associated with occCite queries and data manipulation.
}
\section{Slot... |
####### CALIBRATION WITH COMBINED CLASSIC & PHYLO FEATURES ##########
# MCAR
# Missing Completly at Random
# Sequenced individulas are chosen randomly
##############
### Models ###
##############
# 35%
simpact4ABC.classic.phylo.MCAR.cov.35 <- function(inputvector){
library(EasyABC)
library(R... | /stress_testing/simulation_study_1/calibration.combined.features.phylo.MCAR.study.1.R | no_license | niyongabirejunior/arteta | R | false | false | 195,350 | r | ####### CALIBRATION WITH COMBINED CLASSIC & PHYLO FEATURES ##########
# MCAR
# Missing Completly at Random
# Sequenced individulas are chosen randomly
##############
### Models ###
##############
# 35%
simpact4ABC.classic.phylo.MCAR.cov.35 <- function(inputvector){
library(EasyABC)
library(R... |
#' @title Get Dependency Table
#' @description Get a Table of the Dependencies
#'
#' @param path Path to DESCRIPTION file
#' @param dependencies List of dependencies to parse
#' @param limit_compare only keep rows where a comparison operator is found
#'
#' @return A \code{data.frame} of
#' \describe{
#' \item{name}{nam... | /R/get_dep_table.R | no_license | muschellij2/ghtravis | R | false | false | 1,096 | r | #' @title Get Dependency Table
#' @description Get a Table of the Dependencies
#'
#' @param path Path to DESCRIPTION file
#' @param dependencies List of dependencies to parse
#' @param limit_compare only keep rows where a comparison operator is found
#'
#' @return A \code{data.frame} of
#' \describe{
#' \item{name}{nam... |
#' @title Subsetted mouse ESC `SingleCellExperiment` object
#' @description A dataset containing 300 cells and 2026 genes
#' from two batches of mouse ESC data
#' #@usage data(example_sce, package = 'scMerge')
#'
#' @format A `SingleCellExperiment` object
#' @source \url{https://www.ebi.ac.uk/arrayexpress/experiments/... | /R/data.R | no_license | songzh523/scMerge | R | false | false | 873 | r | #' @title Subsetted mouse ESC `SingleCellExperiment` object
#' @description A dataset containing 300 cells and 2026 genes
#' from two batches of mouse ESC data
#' #@usage data(example_sce, package = 'scMerge')
#'
#' @format A `SingleCellExperiment` object
#' @source \url{https://www.ebi.ac.uk/arrayexpress/experiments/... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Annotate.R
\name{closest_gene_internal}
\alias{closest_gene_internal}
\title{Call the closest gene for a gr and a txdb}
\usage{
closest_gene_internal(gr, txdb)
}
\description{
Call the closest gene for a gr and a txdb
}
| /man/closest_gene_internal.Rd | permissive | mal2017/rosy | R | false | true | 298 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Annotate.R
\name{closest_gene_internal}
\alias{closest_gene_internal}
\title{Call the closest gene for a gr and a txdb}
\usage{
closest_gene_internal(gr, txdb)
}
\description{
Call the closest gene for a gr and a txdb
}
|
############################### HEADER ######################################
# TITLE: ImportProfiles.R
# DESCRIPTION: This script will process/import reservoir Profile Data and Secchi Data to database
# AUTHOR(S): Dan Crocker, Max Nyquist
# DATE LAST UPDATED: 2021-12-23
# GIT REPO:
# R version 4.0.3 (2020-10-... | /src/Wachusett/ImportProfiles.R | no_license | tdrury-DCR/DCR-WIT | R | false | false | 11,760 | r | ############################### HEADER ######################################
# TITLE: ImportProfiles.R
# DESCRIPTION: This script will process/import reservoir Profile Data and Secchi Data to database
# AUTHOR(S): Dan Crocker, Max Nyquist
# DATE LAST UPDATED: 2021-12-23
# GIT REPO:
# R version 4.0.3 (2020-10-... |
## ---- echo = FALSE, message = FALSE--------------------------------------
knitr::opts_chunk$set(collapse = T, comment = "#>")
options(tibble.print_min = 4L, tibble.print_max = 4L)
library(rSEA)
## ----data_sim------------------------------------------------------------
set.seed(753) #to get the same result a... | /inst/doc/rSEA_vignette.R | no_license | cran/rSEA | R | false | false | 6,212 | r | ## ---- echo = FALSE, message = FALSE--------------------------------------
knitr::opts_chunk$set(collapse = T, comment = "#>")
options(tibble.print_min = 4L, tibble.print_max = 4L)
library(rSEA)
## ----data_sim------------------------------------------------------------
set.seed(753) #to get the same result a... |
#' @include class_AmChart.R utils_basicClassUnions.R
NULL
#' @title StockPanel class
#' @author datastorm-open
#'
#' @description StockPanel class creates stock panels (charts).
#' AmStockChart can have multiple Stock panels.
#' @details Run \code{api("StockPanel")} for more information and all avalaible properties.
... | /rAmCharts/R/class_StockPanel.R | no_license | ingted/R-Examples | R | false | false | 10,383 | r | #' @include class_AmChart.R utils_basicClassUnions.R
NULL
#' @title StockPanel class
#' @author datastorm-open
#'
#' @description StockPanel class creates stock panels (charts).
#' AmStockChart can have multiple Stock panels.
#' @details Run \code{api("StockPanel")} for more information and all avalaible properties.
... |
#addCIPI2Plot(x, y, confidence_level)
# by Garen Evans, Wright School of Business (2017)
#
# This function adds confidence and prediction intervals
# to a scatter plot, where x = independent variable, and
# y = dependent variable.
#
# Example:
# x <- seq(1, 7)
# y <- 3.4 + 1.5*x + rnorm(length(x), mean=0, sd=2)
# plot(... | /Code/ecmtUtil.R | no_license | Synergist/ECON-4101-Applied-Econometrics | R | false | false | 1,201 | r | #addCIPI2Plot(x, y, confidence_level)
# by Garen Evans, Wright School of Business (2017)
#
# This function adds confidence and prediction intervals
# to a scatter plot, where x = independent variable, and
# y = dependent variable.
#
# Example:
# x <- seq(1, 7)
# y <- 3.4 + 1.5*x + rnorm(length(x), mean=0, sd=2)
# plot(... |
# The dataset has 2,075,259 rows and 9 columns, ~ 130 MB txt file.
# Estimated memory requirements: 2M rows * 9 columns * 8 bytes/value ~ 144 MB.
# Read data for the two dates of interest: 2007-02-01 and 2007-02-02.
df <- "./data/household_power_consumption.txt"
data <- read.table(text = grep("^[1,2]/2/2007", readL... | /plot2.R | no_license | cstanca1/Electric-Power-Consumption-Analysis | R | false | false | 825 | r | # The dataset has 2,075,259 rows and 9 columns, ~ 130 MB txt file.
# Estimated memory requirements: 2M rows * 9 columns * 8 bytes/value ~ 144 MB.
# Read data for the two dates of interest: 2007-02-01 and 2007-02-02.
df <- "./data/household_power_consumption.txt"
data <- read.table(text = grep("^[1,2]/2/2007", readL... |
#Movie Recommendation Engine
library(dplyr)
library(tidyverse)
library(ggplot2)
library(scrubr)
library(reshape2)
library(scales)
setwd('/home/gabe/Documents/School 2020/Spring 2nd 8 Weeks/Data Wrangling/data/movies/ml-100k')
#Loading Tables
dat <- read.table('u.data', col.names = c("user_id", "item_id", "rating", "... | /AssignMovie19Apr20.R | no_license | gmaubrrriaeyl/python-ii | R | false | false | 3,799 | r | #Movie Recommendation Engine
library(dplyr)
library(tidyverse)
library(ggplot2)
library(scrubr)
library(reshape2)
library(scales)
setwd('/home/gabe/Documents/School 2020/Spring 2nd 8 Weeks/Data Wrangling/data/movies/ml-100k')
#Loading Tables
dat <- read.table('u.data', col.names = c("user_id", "item_id", "rating", "... |
## clustering
library(caret)
set.seed(1712)
# 1. train, test dataset
inTrain <- createDataPartition(y = iris$Species, p = 0.7, list = F)
training <- iris[inTrain,]
testing <- iris[-inTrain,]
training
testing
# 2. standization
training.data <- scale(training[-5])
summary(training.data)
# 3. 3 clusters
iris.kme... | /sta_kmeans_2.R | no_license | plus4u/R | R | false | false | 2,943 | r | ## clustering
library(caret)
set.seed(1712)
# 1. train, test dataset
inTrain <- createDataPartition(y = iris$Species, p = 0.7, list = F)
training <- iris[inTrain,]
testing <- iris[-inTrain,]
training
testing
# 2. standization
training.data <- scale(training[-5])
summary(training.data)
# 3. 3 clusters
iris.kme... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/saga_pointsthinning.R
\name{saga_pointsthinning}
\alias{saga_pointsthinning}
\title{QGIS algorithm Points thinning}
\usage{
saga_pointsthinning(
POINTS = qgisprocess::qgis_default_value(),
FIELD = qgisprocess::qgis_default_value(),
RESO... | /man/saga_pointsthinning.Rd | permissive | VB6Hobbyst7/r_package_qgis | R | false | true | 1,296 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/saga_pointsthinning.R
\name{saga_pointsthinning}
\alias{saga_pointsthinning}
\title{QGIS algorithm Points thinning}
\usage{
saga_pointsthinning(
POINTS = qgisprocess::qgis_default_value(),
FIELD = qgisprocess::qgis_default_value(),
RESO... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/helpers.R
\name{hugeKmb}
\alias{hugeKmb}
\title{Internal wrapper function to implement rank-based correlation to huge.mb function in "huge" package.}
\usage{
hugeKmb(data, lambda, type = "trunc", sym = "or", verbose = TRUE)
}
\arguments{
\ite... | /man/hugeKmb.Rd | no_license | muellsen/SPRING | R | false | true | 1,150 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/helpers.R
\name{hugeKmb}
\alias{hugeKmb}
\title{Internal wrapper function to implement rank-based correlation to huge.mb function in "huge" package.}
\usage{
hugeKmb(data, lambda, type = "trunc", sym = "or", verbose = TRUE)
}
\arguments{
\ite... |
#' @title A function to launch interactive plotting session on Shniy
#' @description Provides gui to set plotting parameter for area plot.
#' @param D A dataframe of IAMC data in tibble format to produce area plots.
#' @param R A dataframe of data aggregation rules (meta data).
#' @param language A string of language f... | /R/mipplot_interactive_area.R | permissive | GISerDaiShaoqing/mipplot | R | false | false | 7,836 | r | #' @title A function to launch interactive plotting session on Shniy
#' @description Provides gui to set plotting parameter for area plot.
#' @param D A dataframe of IAMC data in tibble format to produce area plots.
#' @param R A dataframe of data aggregation rules (meta data).
#' @param language A string of language f... |
data('dive.sim')
attach(dive.sim)
# build partition of sim$times that 1) includes sim$times, and 2) has a
# maximum increment of 100
times.refined = refine.partition(breaks = sim$times, max.width = 100)
# find where the original times appear in the refined partition
refined.mapping = sapply(sim$times, function(x) wh... | /examples/refine.partition.R | no_license | jmhewitt/dsdive | R | false | false | 601 | r | data('dive.sim')
attach(dive.sim)
# build partition of sim$times that 1) includes sim$times, and 2) has a
# maximum increment of 100
times.refined = refine.partition(breaks = sim$times, max.width = 100)
# find where the original times appear in the refined partition
refined.mapping = sapply(sim$times, function(x) wh... |
###DeMixT step II function
DeMixT.S2 <- function(inputdata, groupid, givenpi,ninteg = 50, filter.out = TRUE, filter.option = 1, nthread=-1){
core.num <- round(detectCores())-1
if(nthread == -1) nthread = core.num
sample.id <- colnames(inputdata[, groupid == 3])
if(is.null(row.names(inputdata))) row.names(i... | /DeMixT_0.1/R/DeMixT.S2.R | no_license | wwylab/DeMixTallmaterials | R | false | false | 2,991 | r | ###DeMixT step II function
DeMixT.S2 <- function(inputdata, groupid, givenpi,ninteg = 50, filter.out = TRUE, filter.option = 1, nthread=-1){
core.num <- round(detectCores())-1
if(nthread == -1) nthread = core.num
sample.id <- colnames(inputdata[, groupid == 3])
if(is.null(row.names(inputdata))) row.names(i... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/application_visualization.R
\name{make_heatmap_ggplot}
\alias{make_heatmap_ggplot}
\title{Make a ggplot heatmap object from an input matrix (2-color).}
\usage{
make_heatmap_ggplot(matrix, y_name, x_name, y_axis = TRUE,x_axis = TRUE, x_axis_po... | /man/make_heatmap_ggplot.Rd | no_license | saeyslab/nichenetr | R | false | true | 1,928 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/application_visualization.R
\name{make_heatmap_ggplot}
\alias{make_heatmap_ggplot}
\title{Make a ggplot heatmap object from an input matrix (2-color).}
\usage{
make_heatmap_ggplot(matrix, y_name, x_name, y_axis = TRUE,x_axis = TRUE, x_axis_po... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utils.R
\name{scale_to_unit}
\alias{scale_to_unit}
\title{Scale values to the unit interval}
\usage{
scale_to_unit(vals)
}
\arguments{
\item{vals}{A \code{numeric} vector of values to be scaled into the closed
interval [0, 1].}
}
\description... | /man/scale_to_unit.Rd | permissive | rfherrerac/medoutcon | R | false | true | 377 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utils.R
\name{scale_to_unit}
\alias{scale_to_unit}
\title{Scale values to the unit interval}
\usage{
scale_to_unit(vals)
}
\arguments{
\item{vals}{A \code{numeric} vector of values to be scaled into the closed
interval [0, 1].}
}
\description... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/SS_readstarter.R
\name{SS_readstarter}
\alias{SS_readstarter}
\title{Read Stock Synthesis starter file as a list}
\usage{
SS_readstarter(file = "starter.ss", verbose = TRUE)
}
\arguments{
\item{file}{Filename either with full path or relative... | /man/SS_readstarter.Rd | no_license | r4ss/r4ss | R | false | true | 1,552 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/SS_readstarter.R
\name{SS_readstarter}
\alias{SS_readstarter}
\title{Read Stock Synthesis starter file as a list}
\usage{
SS_readstarter(file = "starter.ss", verbose = TRUE)
}
\arguments{
\item{file}{Filename either with full path or relative... |
## Contains functions to create a "super-matrix" object and cache its inverse.
## Assumes the matrix supplied is invertible.
## Create a special matrix that returns a list of functions to:
## get matrix
## get the inverse of the matrix
## set matrix values
## set the inverse of the matrix
makeCacheMatrix <- function(x... | /cachematrix.R | no_license | nxd1/ProgrammingAssignment2 | R | false | false | 1,233 | r | ## Contains functions to create a "super-matrix" object and cache its inverse.
## Assumes the matrix supplied is invertible.
## Create a special matrix that returns a list of functions to:
## get matrix
## get the inverse of the matrix
## set matrix values
## set the inverse of the matrix
makeCacheMatrix <- function(x... |
a <- function(x) sum(x) | /features/steps/r_lib/a.r | permissive | davidrichards/statisticus | R | false | false | 23 | r | a <- function(x) sum(x) |
#' unlist_null2na
#'
#' This function converts NULL to NA and then apply unlist().
#' Inspired by https://stackoverflow.com/questions/2991514/prevent-unlist-to-drop-null-values
#'
#' @param x input list
#' @param ... passed to unlist()
#' @keywords unlist, NULL, NA
#' @export
#' @examples
#' x <- list(NULL, 1, 2)
#' un... | /R/unlist_null2na.R | no_license | sleeubc/sanghoon | R | false | false | 446 | r | #' unlist_null2na
#'
#' This function converts NULL to NA and then apply unlist().
#' Inspired by https://stackoverflow.com/questions/2991514/prevent-unlist-to-drop-null-values
#'
#' @param x input list
#' @param ... passed to unlist()
#' @keywords unlist, NULL, NA
#' @export
#' @examples
#' x <- list(NULL, 1, 2)
#' un... |
# Requires input to be character
p_load_current_single_gh <-
function (package, dependencies = TRUE, ...){
## isolate package name from script
pack <- parse_git_repo(package)[["repo"]]
# Attempt to install
p_install_gh(package, dependencies = dependencies, ...)
return(suppressWarnings(r... | /R/p_load_current_single_gh.R | no_license | cran/pacman | R | false | false | 434 | r | # Requires input to be character
p_load_current_single_gh <-
function (package, dependencies = TRUE, ...){
## isolate package name from script
pack <- parse_git_repo(package)[["repo"]]
# Attempt to install
p_install_gh(package, dependencies = dependencies, ...)
return(suppressWarnings(r... |
##
## Some set operations
##
cardOrder <- function(xlist){
x <- xlist
len <- unlist(lapply(x,length))
unlen <- sort(unique(len))
x2 <- NULL
for (i in seq(along=unlen)){
x2 <- c(x2, x[len==unlen[i]])
}
x2
}
is.subset <- function(x,y){
setequal(intersect(x,y),x)
}
is.subsetList ... | /R/setop.R | no_license | cran/mimR | R | false | false | 908 | r | ##
## Some set operations
##
cardOrder <- function(xlist){
x <- xlist
len <- unlist(lapply(x,length))
unlen <- sort(unique(len))
x2 <- NULL
for (i in seq(along=unlen)){
x2 <- c(x2, x[len==unlen[i]])
}
x2
}
is.subset <- function(x,y){
setequal(intersect(x,y),x)
}
is.subsetList ... |
MeanDirection3D <- function (coord)
{
# the mean vector parameters are calculated by means
# of vectorial addition
# unit vectors are not assumed
x <- coord[, 1]
y <- coord[, 2]
z <- coord[, 3]
n_elements = length(x)
R = sqrt((sum(x) * sum(x)) + (sum(y) * sum(y)) + (sum(z) *
... | /VecStatGraphs3D/R/MeanDirection3D.R | no_license | ingted/R-Examples | R | false | false | 964 | r | MeanDirection3D <- function (coord)
{
# the mean vector parameters are calculated by means
# of vectorial addition
# unit vectors are not assumed
x <- coord[, 1]
y <- coord[, 2]
z <- coord[, 3]
n_elements = length(x)
R = sqrt((sum(x) * sum(x)) + (sum(y) * sum(y)) + (sum(z) *
... |
#############################################################################################
### This file load data relative to the electric power consumption
### for the period covering 2007-02-01 and 2007-02-02.
### Different electrical quantities and some sub-metering values are available.
### An histogram of the... | /plot1.R | no_license | rturcotte861/ExData_Plotting1 | R | false | false | 1,959 | r | #############################################################################################
### This file load data relative to the electric power consumption
### for the period covering 2007-02-01 and 2007-02-02.
### Different electrical quantities and some sub-metering values are available.
### An histogram of the... |
#In this script, I'll use an NMDS plot to see if my technical replicates are similar.
#### IMPORT DATA ####
SRMAreas <- read.csv("analyses/7-SRM/2017-11-05-Gigas-SRM-Good-Samples-Total-Area.csv", na.strings = "#N/A") #Specify Skyline's special way of designating N/A values
head(SRMAreas) #Confirm import
tail(SRMAreas... | /analyses/7-SRM/2017-11-05-NMDS-for-Technical-Replication.R | no_license | RobertsLab/paper-gigas-DNR-proteomics | R | false | false | 8,700 | r | #In this script, I'll use an NMDS plot to see if my technical replicates are similar.
#### IMPORT DATA ####
SRMAreas <- read.csv("analyses/7-SRM/2017-11-05-Gigas-SRM-Good-Samples-Total-Area.csv", na.strings = "#N/A") #Specify Skyline's special way of designating N/A values
head(SRMAreas) #Confirm import
tail(SRMAreas... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/dq_render_svg.R
\name{dq_render_svg}
\alias{dq_render_svg}
\title{Render ggplot2 figure as svg}
\usage{
dq_render_svg(
gg,
path = NULL,
width = 1200,
height = 500,
alt = "",
pdf = FALSE,
png = FALSE,
delete_file ... | /old_dependencies/dqshiny/man/dq_render_svg.Rd | no_license | bigliolimatteo/time_series_modeling_app | R | false | true | 1,659 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/dq_render_svg.R
\name{dq_render_svg}
\alias{dq_render_svg}
\title{Render ggplot2 figure as svg}
\usage{
dq_render_svg(
gg,
path = NULL,
width = 1200,
height = 500,
alt = "",
pdf = FALSE,
png = FALSE,
delete_file ... |
library(tidyverse)
library(readxl)
library(genbankr)
library(Biostrings)
library(rhmmer)
# Neighrborhood Defense Score ---------------------------------------------
neighborhood_defense_function <-
function(neighborhood.file,
upstream.window.size,
downstream.window.size,
output.loc)... | /Updated_Defense_Score.R | no_license | n-fernandez-1/DnmA_Manuscript_Scripts | R | false | false | 9,866 | r | library(tidyverse)
library(readxl)
library(genbankr)
library(Biostrings)
library(rhmmer)
# Neighrborhood Defense Score ---------------------------------------------
neighborhood_defense_function <-
function(neighborhood.file,
upstream.window.size,
downstream.window.size,
output.loc)... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/generate_function_documentation.R
\name{decode_var_first_line_of_desc}
\alias{decode_var_first_line_of_desc}
\title{Title}
\usage{
decode_var_first_line_of_desc(data_line, data_line_num, prev_state,
first_token_of_next_line)
}
\arguments{
\... | /man/decode_var_first_line_of_desc.Rd | no_license | langfob/docaids | R | false | true | 849 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/generate_function_documentation.R
\name{decode_var_first_line_of_desc}
\alias{decode_var_first_line_of_desc}
\title{Title}
\usage{
decode_var_first_line_of_desc(data_line, data_line_num, prev_state,
first_token_of_next_line)
}
\arguments{
\... |
### R code from vignette source 'DEnss.Rnw'
###################################################
### code chunk number 1: DEnss.Rnw:27-28
###################################################
options(continue = " ", digits = 5)
###################################################
### code chunk number 2: DEnss.Rnw:54-5... | /inst/doc/DEnss.R | no_license | cran/NMOF | R | false | false | 11,936 | r | ### R code from vignette source 'DEnss.Rnw'
###################################################
### code chunk number 1: DEnss.Rnw:27-28
###################################################
options(continue = " ", digits = 5)
###################################################
### code chunk number 2: DEnss.Rnw:54-5... |
## Utility functions shared across reports
## crude correction for possible lag in recording counts (see France, for example)
correctLag <- function(x)
{
n <- length(x)
stopifnot(n > 2)
for (i in seq(2, n-1))
if (x[i] == x[i-1])
x[i] <- sqrt(x[i-1] * x[i+1])
x
}
## doubling tim... | /covid-19/covid-utils.R | no_license | deepayan/deepayan.github.io | R | false | false | 6,281 | r |
## Utility functions shared across reports
## crude correction for possible lag in recording counts (see France, for example)
correctLag <- function(x)
{
n <- length(x)
stopifnot(n > 2)
for (i in seq(2, n-1))
if (x[i] == x[i-1])
x[i] <- sqrt(x[i-1] * x[i+1])
x
}
## doubling tim... |
lik_SAR_UC_conditional <-
function (th, env)
.Call("lik_SAR_UC_conditional", th, env, PACKAGE = "ProbitSpatial")
| /R/lik_SAR_UC_conditional.R | no_license | becarioprecario/ProbitSpatial | R | false | false | 114 | r | lik_SAR_UC_conditional <-
function (th, env)
.Call("lik_SAR_UC_conditional", th, env, PACKAGE = "ProbitSpatial")
|
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/plots.R
\name{QQplot}
\alias{QQplot}
\alias{QQplot.default}
\alias{QQplot.dist}
\alias{QQnorm}
\title{Quantile-Quantile Plot}
\usage{
QQplot(
d1,
d2,
line = TRUE,
col = "#122e94",
line_col = "#f28df9",
xlab = deparse(substitute(d1... | /man/QQplot.Rd | no_license | cran/mistr | R | false | true | 2,537 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/plots.R
\name{QQplot}
\alias{QQplot}
\alias{QQplot.default}
\alias{QQplot.dist}
\alias{QQnorm}
\title{Quantile-Quantile Plot}
\usage{
QQplot(
d1,
d2,
line = TRUE,
col = "#122e94",
line_col = "#f28df9",
xlab = deparse(substitute(d1... |
#Julian Ramirez-Villegas
#UoL / CCAFS / CIAT
#Apr 2014
stop("!")
#############################################################################################
####### See wfd_wfdei_checks.R. I realised the annual precip totals were ok, so calculated
####### totals of precip for the Sacks et al. (2010) defined growing s... | /toe-global-crops/wfdei_calc_prec_gdd.R | no_license | CIAT-DAPA/dapa-climate-change | R | false | false | 13,392 | r | #Julian Ramirez-Villegas
#UoL / CCAFS / CIAT
#Apr 2014
stop("!")
#############################################################################################
####### See wfd_wfdei_checks.R. I realised the annual precip totals were ok, so calculated
####### totals of precip for the Sacks et al. (2010) defined growing s... |
library(simMSM)
### Name: mplskeleton
### Title: Build Up a Model Parameter List Skeleton
### Aliases: mplskeleton
### ** Examples
## Two state-type model with transient state-types 1 and 2:
tra2 <- matrix(ncol = 2, nrow = 2, data = FALSE)
tra2[1, 2] <- tra2[2, 1] <- TRUE
mplskeleton(tmat = tra2)
## Illness-death ... | /data/genthat_extracted_code/simMSM/examples/mplskeleton.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 490 | r | library(simMSM)
### Name: mplskeleton
### Title: Build Up a Model Parameter List Skeleton
### Aliases: mplskeleton
### ** Examples
## Two state-type model with transient state-types 1 and 2:
tra2 <- matrix(ncol = 2, nrow = 2, data = FALSE)
tra2[1, 2] <- tra2[2, 1] <- TRUE
mplskeleton(tmat = tra2)
## Illness-death ... |
library(BIOdry)
### Name: rtimes
### Title: Time-units synchronization
### Aliases: rtimes
### ** Examples
## row names of a vector
fy <- function(y,span){(y - span):y}
x <- c(fy(2005,5),fy(2007,10))
## (not run) Simulating the vector
r <- abs(rnorm(length(x)))
names(r) <- x
## (not run) computing the synchronized... | /data/genthat_extracted_code/BIOdry/examples/rtimes.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 447 | r | library(BIOdry)
### Name: rtimes
### Title: Time-units synchronization
### Aliases: rtimes
### ** Examples
## row names of a vector
fy <- function(y,span){(y - span):y}
x <- c(fy(2005,5),fy(2007,10))
## (not run) Simulating the vector
r <- abs(rnorm(length(x)))
names(r) <- x
## (not run) computing the synchronized... |
setwd("C:/Users/rhidayatulla/Documents/0000 Data Science/Coursera/Exploratory Data Analysis")
data1 <- subset(household_power_consumption, Date %in% c("1/2/2007","2/2/2007"))
data1$Date <- as.Date(data1$Date, format="%d/%m/%Y")
data1$Global_active_power <- as.numeric(data1$Global_active_power)
hist(data1$Global... | /Plot1.R | no_license | rahmat160510/ExData_Plotting1 | R | false | false | 494 | r | setwd("C:/Users/rhidayatulla/Documents/0000 Data Science/Coursera/Exploratory Data Analysis")
data1 <- subset(household_power_consumption, Date %in% c("1/2/2007","2/2/2007"))
data1$Date <- as.Date(data1$Date, format="%d/%m/%Y")
data1$Global_active_power <- as.numeric(data1$Global_active_power)
hist(data1$Global... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/data.R
\docType{data}
\name{joint14em}
\alias{joint14em}
\title{Joint probabilities, n=14, around the empirical median}
\format{
matrix, 13 rows and 7 columns
}
\source{
generated by the function crossrunsymm and
transformed from an Rmpfr arr... | /man/joint14em.Rd | no_license | cran/crossrun | R | false | true | 1,125 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/data.R
\docType{data}
\name{joint14em}
\alias{joint14em}
\title{Joint probabilities, n=14, around the empirical median}
\format{
matrix, 13 rows and 7 columns
}
\source{
generated by the function crossrunsymm and
transformed from an Rmpfr arr... |
symDMatrix <- setClass("symDMatrix", contains = "RowLinkedMatrix")
setValidity("symDMatrix", function(object) {
nBlocks <- nBlocks(object)
# Stop if there are no blocks
if (nBlocks == 0L) {
return("there needs to be at least one block")
}
# Stop if blocks are not of type ColumnLinkedMatrix
... | /R/symDMatrix.R | no_license | QuantGen/symDMatrix | R | false | false | 7,474 | r | symDMatrix <- setClass("symDMatrix", contains = "RowLinkedMatrix")
setValidity("symDMatrix", function(object) {
nBlocks <- nBlocks(object)
# Stop if there are no blocks
if (nBlocks == 0L) {
return("there needs to be at least one block")
}
# Stop if blocks are not of type ColumnLinkedMatrix
... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/getSequencesWithLargestBetweenGroupVariation.R
\name{getSequencesWithLargestBetweenGroupVariation}
\alias{getSequencesWithLargestBetweenGroupVariation}
\title{Get sequences with the largest between group variation}
\usage{
getSequencesWithLar... | /man/getSequencesWithLargestBetweenGroupVariation.Rd | no_license | graumannlab/readat | R | false | true | 1,108 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/getSequencesWithLargestBetweenGroupVariation.R
\name{getSequencesWithLargestBetweenGroupVariation}
\alias{getSequencesWithLargestBetweenGroupVariation}
\title{Get sequences with the largest between group variation}
\usage{
getSequencesWithLar... |
n <- 1039
mean <- 704
sd <- 300
SE <- sd / sqrt(n)
MoE <- 2 * SE; MoE # margin of error for 95% CI
mean - MoE # lower limit of 95% CI
mean + MoE # upper limit of 95% CI
| /inst/snippets/Exploration3.4.6.R | no_license | rpruim/ISIwithR | R | false | false | 196 | r | n <- 1039
mean <- 704
sd <- 300
SE <- sd / sqrt(n)
MoE <- 2 * SE; MoE # margin of error for 95% CI
mean - MoE # lower limit of 95% CI
mean + MoE # upper limit of 95% CI
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.