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 |
|---|---|---|---|---|---|---|---|---|---|
### =========================================================================
### TENxMatrixSeed objects
### -------------------------------------------------------------------------
setClass("TENxMatrixSeed",
contains="Array",
representation(
filepath="character", # Absolute path to the HDF5 file ... | /R/TENxMatrixSeed-class.R | no_license | muschellij2/HDF5Array | R | false | false | 17,938 | r | ### =========================================================================
### TENxMatrixSeed objects
### -------------------------------------------------------------------------
setClass("TENxMatrixSeed",
contains="Array",
representation(
filepath="character", # Absolute path to the HDF5 file ... |
library(ape)
testtree <- read.tree("6618_5.txt")
unrooted_tr <- unroot(testtree)
write.tree(unrooted_tr, file="6618_5_unrooted.txt") | /codeml_files/newick_trees_processed/6618_5/rinput.R | no_license | DaniBoo/cyanobacteria_project | R | false | false | 135 | r | library(ape)
testtree <- read.tree("6618_5.txt")
unrooted_tr <- unroot(testtree)
write.tree(unrooted_tr, file="6618_5_unrooted.txt") |
% Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/functions.r
\name{adMCMC}
\alias{adMCMC}
\title{Estimate a continuous posterior distribution via adaptive MCMC.}
\usage{
adMCMC(inits, logLik, logPrior, nIter, nThin, logScaleMCMC = TRUE,
blocks = NULL, ...)
}
\arguments{
\item{init... | /man/adMCMC.Rd | no_license | jknape/stageFreq | R | false | false | 2,733 | rd | % Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/functions.r
\name{adMCMC}
\alias{adMCMC}
\title{Estimate a continuous posterior distribution via adaptive MCMC.}
\usage{
adMCMC(inits, logLik, logPrior, nIter, nThin, logScaleMCMC = TRUE,
blocks = NULL, ...)
}
\arguments{
\item{init... |
#************************************
#
# (C) Copyright IBM Corp. 2015
#
# Author: Bradley J Eck
#
#************************************
#' Epanet's Net1 Example
#'
#' A dataset created by reading the Net1.inp file
#' distributed with Epanet using this package's
#' read.inp() function.
#'
#' @name Net... | /epanetReader/R/Net1rpt-data.r | no_license | ingted/R-Examples | R | false | false | 445 | r | #************************************
#
# (C) Copyright IBM Corp. 2015
#
# Author: Bradley J Eck
#
#************************************
#' Epanet's Net1 Example
#'
#' A dataset created by reading the Net1.inp file
#' distributed with Epanet using this package's
#' read.inp() function.
#'
#' @name Net... |
## Load libraries ================================
library(tidyverse)
library(lubridate)
library(forecast)
## Load preprocessed data ========================
powerData <- readRDS('./output/powerData.RDS')
## Create data per week per submeter ==========================
powerWeek <- powerData %>%
group_by(year, mont... | /IoT/R/week_profile.R | no_license | Taros007/ubiqum_projects | R | false | false | 1,807 | r | ## Load libraries ================================
library(tidyverse)
library(lubridate)
library(forecast)
## Load preprocessed data ========================
powerData <- readRDS('./output/powerData.RDS')
## Create data per week per submeter ==========================
powerWeek <- powerData %>%
group_by(year, mont... |
library(tm)
library(topicmodels)
dtm<-readRDS("dtm.rds")
idx<-unlist(lapply(which(grepl('clinton', dtm$dimnames$Terms)), function(x) which(dtm$j %in% x)))
dtm.clinton <- dtm[ sort(unique(dtm$i[idx])),]
dtm.clinton <- removeSparseTerms(dtm.clinton,0.995)
ui.clinton = unique(dtm.clinton$i)
dtm.clinton = dtm.clinton[ui.c... | /clinton_trump_analysis2.R | no_license | milkha/FBElec16 | R | false | false | 1,452 | r | library(tm)
library(topicmodels)
dtm<-readRDS("dtm.rds")
idx<-unlist(lapply(which(grepl('clinton', dtm$dimnames$Terms)), function(x) which(dtm$j %in% x)))
dtm.clinton <- dtm[ sort(unique(dtm$i[idx])),]
dtm.clinton <- removeSparseTerms(dtm.clinton,0.995)
ui.clinton = unique(dtm.clinton$i)
dtm.clinton = dtm.clinton[ui.c... |
#Tracks EON_ Figure 1B, Figure 2A, Fig S5A
##Read Data EONs
timewtmengod<- read.csv2("wtmengod_EONSkin.csv", header=TRUE)
View(timewtmengod)
subtabletEON = rbind( timewtmengod[grep( "EON", timewtmengod[, 1] ), ])
View(subtabletEON)
## Read data Control
WTEON_Dis = rbind( subtabletEON[grep( "wt", subtabletEON[, 1] ), ])... | /Figure1B_2A_S5A_3C_EONs_control_neurog1_ody_me_res_sur_Track.R | no_license | BladerLab/Aguillon_2020 | R | false | false | 14,677 | r | #Tracks EON_ Figure 1B, Figure 2A, Fig S5A
##Read Data EONs
timewtmengod<- read.csv2("wtmengod_EONSkin.csv", header=TRUE)
View(timewtmengod)
subtabletEON = rbind( timewtmengod[grep( "EON", timewtmengod[, 1] ), ])
View(subtabletEON)
## Read data Control
WTEON_Dis = rbind( subtabletEON[grep( "wt", subtabletEON[, 1] ), ])... |
#' Pixel_shuffle
#'
#' Rearranges elements in a tensor of shape \eqn{(*, C \times r^2, H, W)} to a
#' tensor of shape \eqn{(*, C, H \times r, W \times r)}.
#'
#' @param input (Tensor) the input tensor
#' @param upscale_factor (int) factor to increase spatial resolution by
#'
#' @export
nnf_pixel_shuffle <- function(inp... | /R/nnf-pixelshuffle.R | permissive | mlverse/torch | R | false | false | 389 | r | #' Pixel_shuffle
#'
#' Rearranges elements in a tensor of shape \eqn{(*, C \times r^2, H, W)} to a
#' tensor of shape \eqn{(*, C, H \times r, W \times r)}.
#'
#' @param input (Tensor) the input tensor
#' @param upscale_factor (int) factor to increase spatial resolution by
#'
#' @export
nnf_pixel_shuffle <- function(inp... |
rm(list = ls())
data <- read.table("household_power_consumption.txt", header = T,
sep = ";", na.strings = "?")
# convert the date variable to Date class
data$Date <- as.Date(data$Date, format = "%d/%m/%Y")
# Subset the data
data <- subset(data, subset = (Date >= "2007-02-01" & Date <= "2007-02-02")... | /plot2.R | no_license | Joel11-N/ExploratoryDataAnalisisCourseProject | R | false | false | 681 | r | rm(list = ls())
data <- read.table("household_power_consumption.txt", header = T,
sep = ";", na.strings = "?")
# convert the date variable to Date class
data$Date <- as.Date(data$Date, format = "%d/%m/%Y")
# Subset the data
data <- subset(data, subset = (Date >= "2007-02-01" & Date <= "2007-02-02")... |
## Plot 3
## try to read the data file from the working directory
data <- 0
data <- read.table('household_power_consumption.txt', header = TRUE, sep=";")
## if the file is absent, download it from the internet
if (length(data)==1) {
code <- download.file("https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2... | /plot3.R | no_license | dpol2000/ExData_Plotting1 | R | false | false | 1,722 | r | ## Plot 3
## try to read the data file from the working directory
data <- 0
data <- read.table('household_power_consumption.txt', header = TRUE, sep=";")
## if the file is absent, download it from the internet
if (length(data)==1) {
code <- download.file("https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2... |
vecteur_1 <- 1:5
vecteur_2 <- c(1, 4, 9, -2, -1, 4:9)
vecteur_3 <- c(1, 4, 9, -2, 1)
vecteur_4 <- c(1, 4, 9, NA, -1)
n_1 <- length(vecteur_1)
prod(vecteur_1)^(1 / n_1)
# Exercices ---------------------------------------------------------------
# Dans ce document, on vous fournit le script pour calculer la moyenne
# ... | /Exercices/partie_1/exemple_1.R | no_license | vigou3/tests-automatises-en-r | R | false | false | 1,598 | r | vecteur_1 <- 1:5
vecteur_2 <- c(1, 4, 9, -2, -1, 4:9)
vecteur_3 <- c(1, 4, 9, -2, 1)
vecteur_4 <- c(1, 4, 9, NA, -1)
n_1 <- length(vecteur_1)
prod(vecteur_1)^(1 / n_1)
# Exercices ---------------------------------------------------------------
# Dans ce document, on vous fournit le script pour calculer la moyenne
# ... |
#predicting photosythesis
#A = mmol CO2 m-2 s-1
#A=7.309*log(height) - 23.612 #note that log in R is ln
#equation for total leaf area:van pelt et al 2016?
#LA = x*height....blah
#y = -0.0819x2 + 10.867x - 176.95#stand in
####### calculate estimated productivity given different potential G fractions across all heig... | /scripts/paper 2/photosyth and uptake functions.R | no_license | alanaroseo/fogdata | R | false | false | 1,733 | r |
#predicting photosythesis
#A = mmol CO2 m-2 s-1
#A=7.309*log(height) - 23.612 #note that log in R is ln
#equation for total leaf area:van pelt et al 2016?
#LA = x*height....blah
#y = -0.0819x2 + 10.867x - 176.95#stand in
####### calculate estimated productivity given different potential G fractions across all heig... |
prepare_dumbell <- function(graph_type){
if(graph_type == 'top'){
data_for_graph <- data_for_analysis %>% arrange(`Budget Difference`) %>% tail(10)
} else {
data_for_graph <- data_for_analysis %>% arrange(`Budget Difference`) %>% head(10)
}
graph_for_analysis <- data_for_graph
graph_for_analys... | /utils/helpers.R | no_license | apoorv74/OBI-data-explorer | R | false | false | 1,436 | r | prepare_dumbell <- function(graph_type){
if(graph_type == 'top'){
data_for_graph <- data_for_analysis %>% arrange(`Budget Difference`) %>% tail(10)
} else {
data_for_graph <- data_for_analysis %>% arrange(`Budget Difference`) %>% head(10)
}
graph_for_analysis <- data_for_graph
graph_for_analys... |
#' Gets a table's sample
#'
#' @param con connection
#' @param tbl table name
#' @param column optional column name to apply filter
#' @param value optional column value to apply filter
#' @param n number of rows, defaults to 10.
#'
#' @return a data.frame sample according to specified arguements.
#' @export
#'
psql_st... | /R/psql_stj_sample.R | permissive | thgmoraes/stj | R | false | false | 866 | r | #' Gets a table's sample
#'
#' @param con connection
#' @param tbl table name
#' @param column optional column name to apply filter
#' @param value optional column value to apply filter
#' @param n number of rows, defaults to 10.
#'
#' @return a data.frame sample according to specified arguements.
#' @export
#'
psql_st... |
library(spectrolab)
### Name: max.spectra
### Title: Maximum reflectance
### Aliases: max.spectra
### ** Examples
library(spectrolab)
spec = as.spectra(spec_matrix_example, name_idx = 1)
max(spec)
| /data/genthat_extracted_code/spectrolab/examples/max.spectra.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 204 | r | library(spectrolab)
### Name: max.spectra
### Title: Maximum reflectance
### Aliases: max.spectra
### ** Examples
library(spectrolab)
spec = as.spectra(spec_matrix_example, name_idx = 1)
max(spec)
|
variable_assignment <- 'Data can be in double quotations'
# Single line comment
"Multi line"
assign('variable_assignment2',3)
# keep in quotes if not declared
# new environment
my.environment <- new.env()
assign('var1',10, my.environment)
my.environment$var2 = 1
my.environment1 <- new.env()
assign('var1',10... | /Language/R/Suyog_R.R | permissive | ankschoubey/Personal-Developer-Notes | R | false | false | 1,040 | r |
variable_assignment <- 'Data can be in double quotations'
# Single line comment
"Multi line"
assign('variable_assignment2',3)
# keep in quotes if not declared
# new environment
my.environment <- new.env()
assign('var1',10, my.environment)
my.environment$var2 = 1
my.environment1 <- new.env()
assign('var1',10... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Rfunctions_GC.R
\name{krig.mh.stx_carA_smple}
\alias{krig.mh.stx_carA_smple}
\title{Inverse-Gamma DLM MCMC Simulation}
\usage{
krig.mh.stx_carA_smple(i, datpred, parms, cov_names, linmod, nsize = 800)
}
\arguments{
\item{dat}{vector of length... | /man/krig.mh.stx_carA_smple.Rd | no_license | reich-group/Google-Car | R | false | true | 887 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Rfunctions_GC.R
\name{krig.mh.stx_carA_smple}
\alias{krig.mh.stx_carA_smple}
\title{Inverse-Gamma DLM MCMC Simulation}
\usage{
krig.mh.stx_carA_smple(i, datpred, parms, cov_names, linmod, nsize = 800)
}
\arguments{
\item{dat}{vector of length... |
nullirwsva = function (dat, n.sv, B = 5)
{
n <- ncol(dat)
m <- nrow(dat)
mod = as.matrix(rep(1, n), ncol = 1)
Id <- diag(n)
resid <- dat %*% (Id - mod %*% solve(t(mod) %*% mod) %*%
t(mod))
uu <- eigen(t(resid) %*% resid)
vv <- uu$vectors
ndf <- n - dim(mod)[2]
pprob <- rep(1, m... | /Mengjie/single_cell/R/nullirwsva.R | no_license | MeileiJiang/robust-against-heterogeneity | R | false | false | 837 | r | nullirwsva = function (dat, n.sv, B = 5)
{
n <- ncol(dat)
m <- nrow(dat)
mod = as.matrix(rep(1, n), ncol = 1)
Id <- diag(n)
resid <- dat %*% (Id - mod %*% solve(t(mod) %*% mod) %*%
t(mod))
uu <- eigen(t(resid) %*% resid)
vv <- uu$vectors
ndf <- n - dim(mod)[2]
pprob <- rep(1, m... |
library(shiny)
require(RJSONIO)
require(ggplot2)
require(scales)
# This function is used to access the SODA API and download the data from the NJ Open
# Data website. The funtion takes the year as an input and downloads the first 1000
# entries.
GetData<- function(n){
# Returns the dataframe from the dow... | /server.R | no_license | kuhnrl30/NJPayroll | R | false | false | 3,651 | r | library(shiny)
require(RJSONIO)
require(ggplot2)
require(scales)
# This function is used to access the SODA API and download the data from the NJ Open
# Data website. The funtion takes the year as an input and downloads the first 1000
# entries.
GetData<- function(n){
# Returns the dataframe from the dow... |
\name{psmelt}
\alias{psmelt}
\title{Melt phyloseq data object into large data.frame}
\usage{
psmelt(physeq)
}
\arguments{
\item{physeq}{(Required). An
\code{\link{otu_table-class}} or
\code{\link{phyloseq-class}}. Function most useful for
phyloseq-class.}
}
\value{
A \code{\link{data.frame}}-class table.
}
... | /man/psmelt.Rd | no_license | BioinformaticsArchive/phyloseq | R | false | false | 1,761 | rd | \name{psmelt}
\alias{psmelt}
\title{Melt phyloseq data object into large data.frame}
\usage{
psmelt(physeq)
}
\arguments{
\item{physeq}{(Required). An
\code{\link{otu_table-class}} or
\code{\link{phyloseq-class}}. Function most useful for
phyloseq-class.}
}
\value{
A \code{\link{data.frame}}-class table.
}
... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/pltltn.R
\name{pltltn}
\alias{pltltn}
\title{Correction for p>>n for an object of class \code{Bvs}}
\usage{
pltltn(object)
}
\arguments{
\item{object}{An object of class \code{Bvs} obtained with \code{GibbsBvs}}
}
\value{
\code{pltltn} return... | /man/pltltn.Rd | no_license | comodin19/BayesVarSel | R | false | true | 3,959 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/pltltn.R
\name{pltltn}
\alias{pltltn}
\title{Correction for p>>n for an object of class \code{Bvs}}
\usage{
pltltn(object)
}
\arguments{
\item{object}{An object of class \code{Bvs} obtained with \code{GibbsBvs}}
}
\value{
\code{pltltn} return... |
## Function to run joint models with simulated data
joint_model <- function(structured_data,
unstructured_data,
dat1,
biasfield,
plotting=FALSE,
mesh.edge = c(20,40), # added
... | /Run models joint.R | no_license | ssarahas/MScProject_ISDM | R | false | false | 7,076 | r | ## Function to run joint models with simulated data
joint_model <- function(structured_data,
unstructured_data,
dat1,
biasfield,
plotting=FALSE,
mesh.edge = c(20,40), # added
... |
##manual deisotope
deisotope <- function(data=...){
require(stringr)
str_which(data$isotopes, pattern = "\\+\\d")
data_1 <- data[-str_which(data$isotopes, pattern = "\\+\\d|\\d\\+"),]
return(data_1)}
| /deisotope.R | no_license | tuhulab/bfi-wholegrain | R | false | false | 213 | r | ##manual deisotope
deisotope <- function(data=...){
require(stringr)
str_which(data$isotopes, pattern = "\\+\\d")
data_1 <- data[-str_which(data$isotopes, pattern = "\\+\\d|\\d\\+"),]
return(data_1)}
|
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/s.SGD.R
\name{s.SGD}
\alias{s.SGD}
\title{Stochastic Gradient Descent (SGD) [C, R]}
\usage{
s.SGD(
x,
y = NULL,
x.test = NULL,
y.test = NULL,
x.name = NULL,
y.name = NULL,
model = NULL,
model.control = list(lambda1 = 0, lambda... | /man/s.SGD.Rd | no_license | zeta1999/rtemis | R | false | true | 7,725 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/s.SGD.R
\name{s.SGD}
\alias{s.SGD}
\title{Stochastic Gradient Descent (SGD) [C, R]}
\usage{
s.SGD(
x,
y = NULL,
x.test = NULL,
y.test = NULL,
x.name = NULL,
y.name = NULL,
model = NULL,
model.control = list(lambda1 = 0, lambda... |
#' Prepare object for argument \code{design} of \code{spsurvey.analysis()}
#'
#' This function returns an object to feed the argument \code{design} when
#' creating an object of class \code{spsurvey.analysis}.
#'
#' The argument \code{design} used to create object of class
#' \code{spsurvey.analysis} requires a serie... | /pedometrics/R/coordenadas.R | no_license | ingted/R-Examples | R | false | false | 2,272 | r | #' Prepare object for argument \code{design} of \code{spsurvey.analysis()}
#'
#' This function returns an object to feed the argument \code{design} when
#' creating an object of class \code{spsurvey.analysis}.
#'
#' The argument \code{design} used to create object of class
#' \code{spsurvey.analysis} requires a serie... |
### discreteRoot.R ---
##----------------------------------------------------------------------
## Author: Brice Ozenne
## Created: nov 22 2017 (13:39)
## Version:
## Last-Updated: Feb 10 2023 (09:19)
## By: Thomas Alexander Gerds
## Update #: 250
##----------------------------------------------------... | /R/discreteRoot.R | no_license | tagteam/riskRegression | R | false | false | 11,254 | r | ### discreteRoot.R ---
##----------------------------------------------------------------------
## Author: Brice Ozenne
## Created: nov 22 2017 (13:39)
## Version:
## Last-Updated: Feb 10 2023 (09:19)
## By: Thomas Alexander Gerds
## Update #: 250
##----------------------------------------------------... |
\name{get.model}
\alias{get.model}
\title{Get Model}
\description{
Get the model for a node.
}
\usage{
get.model(domain, node, model.nodes)
}
\arguments{
\item{domain}{an RHugin domain.}
\item{node}{a character string specifying the name of a node in \code{domain}.}
\item{model.nodes}{an optional character ve... | /man/get.model.Rd | no_license | huginexpert/RHugin | R | false | false | 1,799 | rd | \name{get.model}
\alias{get.model}
\title{Get Model}
\description{
Get the model for a node.
}
\usage{
get.model(domain, node, model.nodes)
}
\arguments{
\item{domain}{an RHugin domain.}
\item{node}{a character string specifying the name of a node in \code{domain}.}
\item{model.nodes}{an optional character ve... |
library(dplyr)
library(class)
library(e1071)
library(xgboost)
library(magrittr)
library(dplyr)
library(Matrix)
set.seed(123)
sample_split = function(data,size,n){
sample_data <- data[sample(1:nrow(data), size*3), ]
sample_split <-split(sample_data,
rep(1:3, length.out = nrow(sample_data), ... | /Midterm Project - Heyden.R | no_license | drd4/Practical-Machine-Learning-Project | R | false | false | 2,410 | r | library(dplyr)
library(class)
library(e1071)
library(xgboost)
library(magrittr)
library(dplyr)
library(Matrix)
set.seed(123)
sample_split = function(data,size,n){
sample_data <- data[sample(1:nrow(data), size*3), ]
sample_split <-split(sample_data,
rep(1:3, length.out = nrow(sample_data), ... |
testlist <- list(testX = c(191493125665849920, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), trainX ... | /dann/inst/testfiles/calc_distance_C/AFL_calc_distance_C/calc_distance_C_valgrind_files/1609867321-test.R | no_license | akhikolla/updated-only-Issues | R | false | false | 1,199 | r | testlist <- list(testX = c(191493125665849920, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), trainX ... |
ui<- fluidPage(
tags$head(
tags$style(
".h2,h2 {
font-size: 50px;
font-weight: bold;
font-family: Microsoft JhengHei;
color: white;
position: relative;
top: 15px;};"),
tags$style(
"#currentTime{
color: white;
font-size: 80px;
font-weight: bol... | /dashboard_for_workload/ui.R | no_license | renardbao/shiny_project | R | false | false | 3,225 | r |
ui<- fluidPage(
tags$head(
tags$style(
".h2,h2 {
font-size: 50px;
font-weight: bold;
font-family: Microsoft JhengHei;
color: white;
position: relative;
top: 15px;};"),
tags$style(
"#currentTime{
color: white;
font-size: 80px;
font-weight: bol... |
#Plot 3
with(study_data, plot(datetime, Sub_metering_1, type = "l",
xlab = "", ylab = "Energy sub metering"))
with(study_data, lines(datetime, Sub_metering_2, type = "l", col = "red"))
with(study_data, lines(datetime, Sub_metering_3, type = "l", col = "blue"))
legend("topright", lty=1, col = c("b... | /plot3.R | no_license | yuanyuantulip/Exploratory-Data-Analysis-course-project-1 | R | false | false | 488 | r | #Plot 3
with(study_data, plot(datetime, Sub_metering_1, type = "l",
xlab = "", ylab = "Energy sub metering"))
with(study_data, lines(datetime, Sub_metering_2, type = "l", col = "red"))
with(study_data, lines(datetime, Sub_metering_3, type = "l", col = "blue"))
legend("topright", lty=1, col = c("b... |
# validateModel.R
# third piece of code for the clearScience Demo Project
# takes the output from buildModel(), and fits that model
# on held out validation data
validateModel <- function(returnTwo){
# SOURCE LIBRARIES
require(randomForest)
require(ggplot2)
require(ROCR)
# DEFINE VARIABLES
rfERFit ... | /analysisFunctions/validateModel.R | no_license | erichhuang/clearScience-demo | R | false | false | 3,340 | r | # validateModel.R
# third piece of code for the clearScience Demo Project
# takes the output from buildModel(), and fits that model
# on held out validation data
validateModel <- function(returnTwo){
# SOURCE LIBRARIES
require(randomForest)
require(ggplot2)
require(ROCR)
# DEFINE VARIABLES
rfERFit ... |
rm(list = ls())
library(Daniel)
library(dplyr)
library(nnet)
CalcCImultinom <- function(fit)
{
s <- summary(fit)
coef <- s$coefficients
ses <- s$standard.errors
ci.1 <- coef[1,2] + c(-1, 1)*1.96*ses[1, 2]
ci.2 <- coef[2,2] + c(-1, 1)*1.96*ses[2, 2]
return(rbind(ci.1,ci.2))
}
#key
# A, B,C,D,E,F - betaE[2] =... | /Simulations/Scripts/R/Rare/Scenario 19a/CMPEn50KrareScen19aEE.R | no_license | yadevi/CausalMPE | R | false | false | 4,224 | r | rm(list = ls())
library(Daniel)
library(dplyr)
library(nnet)
CalcCImultinom <- function(fit)
{
s <- summary(fit)
coef <- s$coefficients
ses <- s$standard.errors
ci.1 <- coef[1,2] + c(-1, 1)*1.96*ses[1, 2]
ci.2 <- coef[2,2] + c(-1, 1)*1.96*ses[2, 2]
return(rbind(ci.1,ci.2))
}
#key
# A, B,C,D,E,F - betaE[2] =... |
\name{interpolate.score}
\alias{interpolate.score}
\title{
Interpolate the \code{\link{score()}} of a (sparse) signal down to
base pair level.
}
\description{
Tiling arrays have a lower density of information per kbase.
To compare data measured with such techniques with basepair resolution
obtained from N... | /ngs/R/ngsutils/man/interpolate.score.Rd | no_license | plijnzaad/phtools | R | false | false | 2,235 | rd | \name{interpolate.score}
\alias{interpolate.score}
\title{
Interpolate the \code{\link{score()}} of a (sparse) signal down to
base pair level.
}
\description{
Tiling arrays have a lower density of information per kbase.
To compare data measured with such techniques with basepair resolution
obtained from N... |
fcsFile<-system.file("extdata/List-modeDataFiles","int-10_events_6_parameters.fcs",package="gatingMLData")
gateFile <- system.file("extdata/Gating-MLFiles","23TrLn.xml",package="gatingMLData")
csvFile<-paste(system.file("extdata/ExpectedResults/23TrLn",package="gatingMLData"))
flowEnv=new.env()
read.ga... | /inst/RUnitScript_Files/runit.23TrLn.R | no_license | jspidlen/flowUtils | R | false | false | 1,689 | r | fcsFile<-system.file("extdata/List-modeDataFiles","int-10_events_6_parameters.fcs",package="gatingMLData")
gateFile <- system.file("extdata/Gating-MLFiles","23TrLn.xml",package="gatingMLData")
csvFile<-paste(system.file("extdata/ExpectedResults/23TrLn",package="gatingMLData"))
flowEnv=new.env()
read.ga... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/pdfAndProb.R
\name{getProbForDiscrete}
\alias{getProbForDiscrete}
\title{Get a probability of a discrete value.}
\usage{
getProbForDiscrete(data, value)
}
\arguments{
\item{data}{vector of observations that have the same type as the ... | /man/getProbForDiscrete.Rd | no_license | cran/mmb | R | false | true | 1,134 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/pdfAndProb.R
\name{getProbForDiscrete}
\alias{getProbForDiscrete}
\title{Get a probability of a discrete value.}
\usage{
getProbForDiscrete(data, value)
}
\arguments{
\item{data}{vector of observations that have the same type as the ... |
# 1. Loading and Cleaning Data ------------------------------------------------------------
# This creates a clean data file to merge with pre-NOV 2020 abstractions
# This cleans data from final NOV 2020 abstraction (N=93 aggregate studies)
library(dplyr)
setwd("/Users/kristinandrejko/Box/01-Research/02-SP-AMR/Lance... | /code/00-PneumoAMR-LMicrobe-DataCleaning-AddtStudies.R | no_license | joelewnard/amrPneumo | R | false | false | 10,224 | r | # 1. Loading and Cleaning Data ------------------------------------------------------------
# This creates a clean data file to merge with pre-NOV 2020 abstractions
# This cleans data from final NOV 2020 abstraction (N=93 aggregate studies)
library(dplyr)
setwd("/Users/kristinandrejko/Box/01-Research/02-SP-AMR/Lance... |
# Revision Date: 01-02-2016
outlyx <- function(x, iqr=TRUE, iqrP=2, pc=1,
mv=TRUE, mvP=0.15, plot=TRUE, ...) { # {{{
### Computes outliers within methylomic datasets
# Arguments:
# x : Methylumi/Minfi object or raw betas.
#
# pc : The desired principal component for outlier identifi... | /R/outlyx.R | no_license | schalkwyk/wateRmelon | R | false | false | 5,248 | r | # Revision Date: 01-02-2016
outlyx <- function(x, iqr=TRUE, iqrP=2, pc=1,
mv=TRUE, mvP=0.15, plot=TRUE, ...) { # {{{
### Computes outliers within methylomic datasets
# Arguments:
# x : Methylumi/Minfi object or raw betas.
#
# pc : The desired principal component for outlier identifi... |
c DCNF-Autarky [version 0.0.1].
c Copyright (c) 2018-2019 Swansea University.
c
c Input Clause Count: 77330
c Performing E1-Autarky iteration.
c Remaining clauses count after E-Reduction: 75034
c
c Performing E1-Autarky iteration.
c Remaining clauses count after E-Reduction: 75034
c
c Input Parameter (command line, ... | /code/dcnf-ankit-optimized/Results/QBFLIB-2018/E1/Experiments/Gent-Rowley/Connect4/connect_7x6_3_W/connect_7x6_3_W.R | no_license | arey0pushpa/dcnf-autarky | R | false | false | 18,033 | r | c DCNF-Autarky [version 0.0.1].
c Copyright (c) 2018-2019 Swansea University.
c
c Input Clause Count: 77330
c Performing E1-Autarky iteration.
c Remaining clauses count after E-Reduction: 75034
c
c Performing E1-Autarky iteration.
c Remaining clauses count after E-Reduction: 75034
c
c Input Parameter (command line, ... |
% Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/3_ComplexModels.R
\name{M_M_INF}
\alias{M_M_INF}
\title{Obtains the main characteristics of a M/M/\eqn{\infty} queueing model}
\usage{
M_M_INF(lambda = 3, mu = 6)
}
\arguments{
\item{lambda}{Mean arrival rate}
\item{mu}{Me... | /man/M_M_INF.Rd | no_license | ghobbs9495/arqas | R | false | false | 2,043 | rd | % Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/3_ComplexModels.R
\name{M_M_INF}
\alias{M_M_INF}
\title{Obtains the main characteristics of a M/M/\eqn{\infty} queueing model}
\usage{
M_M_INF(lambda = 3, mu = 6)
}
\arguments{
\item{lambda}{Mean arrival rate}
\item{mu}{Me... |
#' DSAIDE: A package to learn about Dynamical Systems Approaches to Infectious
#' Disease Epidemiology
#'
#' The DSAIDE package provides a number of shiny apps that simulate various
#' infectious disease dynamics models By manipulating the models and working
#' through the instructions provided within the shiny UI, you... | /R/DSAIDE.R | no_license | cgolden1993/DSAIDE | R | false | false | 750 | r | #' DSAIDE: A package to learn about Dynamical Systems Approaches to Infectious
#' Disease Epidemiology
#'
#' The DSAIDE package provides a number of shiny apps that simulate various
#' infectious disease dynamics models By manipulating the models and working
#' through the instructions provided within the shiny UI, you... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Sql.R
\name{lowLevelQuerySql.ffdf}
\alias{lowLevelQuerySql.ffdf}
\title{Low level function for retrieving data to an ffdf object}
\usage{
lowLevelQuerySql.ffdf(connection, query = "", batchSize = "auto",
datesAsString = FALSE)
}
\arguments{... | /man/lowLevelQuerySql.ffdf.Rd | permissive | TriNetX/DatabaseConnector | R | false | true | 1,300 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Sql.R
\name{lowLevelQuerySql.ffdf}
\alias{lowLevelQuerySql.ffdf}
\title{Low level function for retrieving data to an ffdf object}
\usage{
lowLevelQuerySql.ffdf(connection, query = "", batchSize = "auto",
datesAsString = FALSE)
}
\arguments{... |
# user options
my.runs<-
c('Single_species', # Single species
'Diri_Uniform_noNumber_noMesh_Sum_type2',
'Diri_Uniform_noNumber_noMesh_Sum_type3',
'Diri_Uniform_noNumber_noMesh_noSum_type2',
'Diri_Uniform_noNumber_noMesh_noSum_type3',
'Diri_Size_noNumber_noMesh_noSum_type2',
'Diri_Size_noNumber_noMesh_... | /SMS_r_prog/r_prog_less_frequently_used/script-number_model.r | permissive | ices-eg/wg_WGSAM | R | false | false | 12,425 | r | # user options
my.runs<-
c('Single_species', # Single species
'Diri_Uniform_noNumber_noMesh_Sum_type2',
'Diri_Uniform_noNumber_noMesh_Sum_type3',
'Diri_Uniform_noNumber_noMesh_noSum_type2',
'Diri_Uniform_noNumber_noMesh_noSum_type3',
'Diri_Size_noNumber_noMesh_noSum_type2',
'Diri_Size_noNumber_noMesh_... |
% Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/data.R
\docType{data}
\name{CH19TA07}
\alias{CH19TA07}
\title{CH19TA07}
\format{\preformatted{'data.frame': 12 obs. of 4 variables:
$ V1: int 47 43 46 40 62 68 67 71 41 39 ...
$ V2: int 1 1 1 1 2 2 2 2 3 3 ...
$ V3: int 1 1 2 2... | /man/CH19TA07.Rd | no_license | bryangoodrich/ALSM | R | false | false | 440 | rd | % Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/data.R
\docType{data}
\name{CH19TA07}
\alias{CH19TA07}
\title{CH19TA07}
\format{\preformatted{'data.frame': 12 obs. of 4 variables:
$ V1: int 47 43 46 40 62 68 67 71 41 39 ...
$ V2: int 1 1 1 1 2 2 2 2 3 3 ...
$ V3: int 1 1 2 2... |
function(dataset,label_column = "Label"){
colnames(dataset)[which(colnames(dataset)==label_column)]='Label'
Boruta_models=Boruta(Label~.,data=dataset[,-1],doTrace=0)
Boruta_variable_importance <- TentativeRoughFix(Boruta_models)
Boruta_variable_importance <- attStats(Boruta_variable_importance)
Boruta_variabl... | /SKRYPTY/R_SCRIPTS/Scripts/Boruta_feature_selection.R | no_license | MMandziej/praca_magisterska | R | false | false | 725 | r | function(dataset,label_column = "Label"){
colnames(dataset)[which(colnames(dataset)==label_column)]='Label'
Boruta_models=Boruta(Label~.,data=dataset[,-1],doTrace=0)
Boruta_variable_importance <- TentativeRoughFix(Boruta_models)
Boruta_variable_importance <- attStats(Boruta_variable_importance)
Boruta_variabl... |
# Conclusion: use fipscounty. 3271 fipscounties, 410 CBSAs. To compare to Datawork we aggregate JOLTS data to CBSAs.
# Data aggregations needed: for JOLTS, Datawork, and Openjobs, a table with CBSA/County/Month-Yr/#jobs/#stem jobss
| /src/jobsCountTables/makeDataworkJobsTable.R | no_license | uva-bi-sdad/stem_edu | R | false | false | 233 | r | # Conclusion: use fipscounty. 3271 fipscounties, 410 CBSAs. To compare to Datawork we aggregate JOLTS data to CBSAs.
# Data aggregations needed: for JOLTS, Datawork, and Openjobs, a table with CBSA/County/Month-Yr/#jobs/#stem jobss
|
library(xgboost)
library(Matrix)
library(data.table)
#library(bit64, pos = .Machine$integer.max) #junk package that won't let use commercially and also won't let unmask functions even when you specify predescence
library(vtreat)
library(outliers)
library(R.utils)
remove(list = ls())
setwd("C:/Users/Laurae/Documents/Da... | /scripts/Two-Way Outliers.R | no_license | Laurae2/Santander | R | false | false | 12,365 | r | library(xgboost)
library(Matrix)
library(data.table)
#library(bit64, pos = .Machine$integer.max) #junk package that won't let use commercially and also won't let unmask functions even when you specify predescence
library(vtreat)
library(outliers)
library(R.utils)
remove(list = ls())
setwd("C:/Users/Laurae/Documents/Da... |
# Definimos el espacio muestral
m <- factor(c(0,1), levels = c("cara","cruz"))
m <- c(0,1)
x <- sample(m,5,replace = TRUE)
sum(x)/length(x)
x <- sample(m,25,replace = TRUE)
sum(x)/length(x)
x <- sample(m,100,replace = TRUE)
sum(x)/length(x)
x <- sample(m,1000,replace = TRUE)
sum(x)/length(x)
x <- sample(m,1000000,repla... | /probabilidad/probabilidad.R | no_license | jrlacalle/material_docente | R | false | false | 348 | r | # Definimos el espacio muestral
m <- factor(c(0,1), levels = c("cara","cruz"))
m <- c(0,1)
x <- sample(m,5,replace = TRUE)
sum(x)/length(x)
x <- sample(m,25,replace = TRUE)
sum(x)/length(x)
x <- sample(m,100,replace = TRUE)
sum(x)/length(x)
x <- sample(m,1000,replace = TRUE)
sum(x)/length(x)
x <- sample(m,1000000,repla... |
# This script gets all documents (e.g. public comments) from regulations.gov
# UNDER CONSTRUCTION FOR V4
## load required packages
source("setup.R")
# I keep keep data I have already downloaded in ascending order in a directory called "ascending"
directory <- "ascending"
list.files(here::here(directory))
# The api ca... | /functions/regulations-gov-get-all-comments4.R | no_license | zoeang/rulemaking | R | false | false | 4,501 | r | # This script gets all documents (e.g. public comments) from regulations.gov
# UNDER CONSTRUCTION FOR V4
## load required packages
source("setup.R")
# I keep keep data I have already downloaded in ascending order in a directory called "ascending"
directory <- "ascending"
list.files(here::here(directory))
# The api ca... |
#!/usr/bin/env Rscript
suppressMessages(library(Matrix))
suppressMessages(library(parallel))
suppressMessages(library(optparse))
option_list <- list(make_option(c("-m", "--mutation_data"), action = "store", type = "character", help = "Mutation Matrix", default = NULL),
make_option(c("-e", '--expre... | /NetworkProfilesWeighted.R | no_license | ardadurmaz/pancancer-fsm | R | false | false | 4,543 | r | #!/usr/bin/env Rscript
suppressMessages(library(Matrix))
suppressMessages(library(parallel))
suppressMessages(library(optparse))
option_list <- list(make_option(c("-m", "--mutation_data"), action = "store", type = "character", help = "Mutation Matrix", default = NULL),
make_option(c("-e", '--expre... |
squirrels <- read.table('http://www.isi-stats.com/isi2/data/Squirrels.txt', header=T)
glimpse(squirrels)
squirrels <- squirrels %>% mutate(Location = as.factor(Location))
contrasts(squirrels$Location) <- contr.sum
squirrels.lm <- lm(Length~Location,data = squirrels)
summary(squirrels.lm)
anova(squirrels.lm)
R2 <-... | /Lesson5 Code From Class.R | no_license | nick3703/MA376 | R | false | false | 579 | r | squirrels <- read.table('http://www.isi-stats.com/isi2/data/Squirrels.txt', header=T)
glimpse(squirrels)
squirrels <- squirrels %>% mutate(Location = as.factor(Location))
contrasts(squirrels$Location) <- contr.sum
squirrels.lm <- lm(Length~Location,data = squirrels)
summary(squirrels.lm)
anova(squirrels.lm)
R2 <-... |
rm(list=ls())
setwd("~/Dropbox/enseignement/ENSAI/EvaluationDecisionsPubliques/TP")
require(FactoMineR)
# Importation des donnees
temperature <- read.table("data/temperatures.csv",header = TRUE, sep = ";", dec = ".", row.names = 1)
##Stat descriptives (on verifie l'importation des donnees)
summary(temperature)
# Grap... | /enseignements/rcode/mspes/Exercice1.R | permissive | masedki/masedki.github.io | R | false | false | 1,644 | r | rm(list=ls())
setwd("~/Dropbox/enseignement/ENSAI/EvaluationDecisionsPubliques/TP")
require(FactoMineR)
# Importation des donnees
temperature <- read.table("data/temperatures.csv",header = TRUE, sep = ";", dec = ".", row.names = 1)
##Stat descriptives (on verifie l'importation des donnees)
summary(temperature)
# Grap... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/faraway-package.R
\docType{data}
\name{chicago}
\alias{chicago}
\title{Chicago insurance redlining}
\format{
This dataframe contains the following columns \describe{
\item{race}{ racial composition in percent minority }
\item{fire}{ fires pe... | /man/chicago.Rd | no_license | cran/faraway | R | false | true | 1,016 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/faraway-package.R
\docType{data}
\name{chicago}
\alias{chicago}
\title{Chicago insurance redlining}
\format{
This dataframe contains the following columns \describe{
\item{race}{ racial composition in percent minority }
\item{fire}{ fires pe... |
crtrate_UCB = rep(NA,itertimes)
exp_reg_UCB = rep(NA,itertimes)
post_reg_UCB = rep(NA,itertimes)
sum_reg_UCB = rep(NA,itertimes)
for(ldai in 1:itertimes){
usbcal = function(diff,N,N1,n){
ans = (8*N^2*log(N)/(sqrt(N*(4*sqrt(2*log(N)*(2*log(N)+N*diff^2))+8*log(N)+N*diff^2))-diff*N)^2-N1)/n
#ans=0.8
#print((sqrt(2*lo... | /Experiment/UCB.R | no_license | liangdai/online-experiment | R | false | false | 2,766 | r | crtrate_UCB = rep(NA,itertimes)
exp_reg_UCB = rep(NA,itertimes)
post_reg_UCB = rep(NA,itertimes)
sum_reg_UCB = rep(NA,itertimes)
for(ldai in 1:itertimes){
usbcal = function(diff,N,N1,n){
ans = (8*N^2*log(N)/(sqrt(N*(4*sqrt(2*log(N)*(2*log(N)+N*diff^2))+8*log(N)+N*diff^2))-diff*N)^2-N1)/n
#ans=0.8
#print((sqrt(2*lo... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/EPFR.r
\name{sql.median}
\alias{sql.median}
\title{sql.median}
\usage{
sql.median(x, y, n, w = 0.5)
}
\arguments{
\item{x}{= column on which computation is run}
\item{y}{= column on which partitioning is performed}
\item{n}{= SQL statement}... | /man/sql.median.Rd | no_license | vsrimurthy/EPFR | R | false | true | 4,936 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/EPFR.r
\name{sql.median}
\alias{sql.median}
\title{sql.median}
\usage{
sql.median(x, y, n, w = 0.5)
}
\arguments{
\item{x}{= column on which computation is run}
\item{y}{= column on which partitioning is performed}
\item{n}{= SQL statement}... |
library(raster)
# Package to handle raster-formatted spatial data
library(rasterVis)
# The rasterVis package complements the raster package, providing a set of methods for enhanced visualization and interaction
# Defines visualisation methods with 'levelplot'
library(dismo)
# Dismo has the SDM analyses for maxent and s... | /5th Code Pout -Inter-Max_vel-Min_fs-ADry.R | no_license | laxmack21/Severn-Estuary-SDMS | R | false | false | 9,623 | r | library(raster)
# Package to handle raster-formatted spatial data
library(rasterVis)
# The rasterVis package complements the raster package, providing a set of methods for enhanced visualization and interaction
# Defines visualisation methods with 'levelplot'
library(dismo)
# Dismo has the SDM analyses for maxent and s... |
d1 <- tibble::tibble(a = 1:5, b = letters[1:5])
d2 <- tibble::tibble(a = c(1,3:6), b = letters[1:5])
d3 <- tibble::tibble(c = 1:5)
d4 <- tibble::tibble(c = c(1:5,5))
d5 <- tibble::tibble(a = 1:5)
d6 <- tibble::tibble(c = 1:4)
check_cardinality_0_n(d1, a, d2, a)
check_cardinality_0_n(d1, a, d3, c)
check_cardinality_1... | /scratch/other_test.R | permissive | philipp-baumann/dm | R | false | false | 730 | r | d1 <- tibble::tibble(a = 1:5, b = letters[1:5])
d2 <- tibble::tibble(a = c(1,3:6), b = letters[1:5])
d3 <- tibble::tibble(c = 1:5)
d4 <- tibble::tibble(c = c(1:5,5))
d5 <- tibble::tibble(a = 1:5)
d6 <- tibble::tibble(c = 1:4)
check_cardinality_0_n(d1, a, d2, a)
check_cardinality_0_n(d1, a, d3, c)
check_cardinality_1... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/plot.bivden.R, R/plot.msden.R, R/plot.rrs.R,
% R/plot.rrst.R, R/plot.stden.R
\name{plot.bivden}
\alias{plot.bivden}
\alias{plot.rrs}
\alias{plot.msden}
\alias{plot.stden}
\alias{plot.rrst}
\title{Plotting sparr objects}
\usage{
\method{plot... | /sparr/man/plotsparr.Rd | no_license | albrizre/spatstat.revdep | R | false | true | 6,711 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/plot.bivden.R, R/plot.msden.R, R/plot.rrs.R,
% R/plot.rrst.R, R/plot.stden.R
\name{plot.bivden}
\alias{plot.bivden}
\alias{plot.rrs}
\alias{plot.msden}
\alias{plot.stden}
\alias{plot.rrst}
\title{Plotting sparr objects}
\usage{
\method{plot... |
#define the file
thefile <- "./data/household_power_consumption.txt"
#read the file
thedata <- read.table(thefile, header=TRUE, sep=";", na.string="?")
#subset data to contain only the important period
subset_data <- subset(thedata, Date %in% c("1/2/2007","2/2/2007"))
rm(thedata)
#open a png device
png("plot3.png", ... | /plot3.R | no_license | kurowska/ExData_Plotting1 | R | false | false | 1,213 | r | #define the file
thefile <- "./data/household_power_consumption.txt"
#read the file
thedata <- read.table(thefile, header=TRUE, sep=";", na.string="?")
#subset data to contain only the important period
subset_data <- subset(thedata, Date %in% c("1/2/2007","2/2/2007"))
rm(thedata)
#open a png device
png("plot3.png", ... |
# *********************************************************************************************
# Title : Seeded KMeans
# Function : seeded_kmeans
# Created by: Owner
# Created on: 2021/01/26
# URL : https://dicits.ugr.es/software/SSLR/reference/seeded_kmeans.html
# ******************************************... | /library/SSLR/function/clustering/seeded_kmeans.R | no_license | delta0726/r-semi_supervised | R | false | false | 1,541 | r | # *********************************************************************************************
# Title : Seeded KMeans
# Function : seeded_kmeans
# Created by: Owner
# Created on: 2021/01/26
# URL : https://dicits.ugr.es/software/SSLR/reference/seeded_kmeans.html
# ******************************************... |
library(tidyverse)
library(data.table)
library(plotly)
#################################################
# ANALYSIS #
#################################################
data <- read.csv("Data/data.csv")
native_only <- data %>%
filter(AmIAKN == "Yes")
non_native <- data %>%
... | /native.R | permissive | marinawooden/children-in-foster-care | R | false | false | 11,946 | r | library(tidyverse)
library(data.table)
library(plotly)
#################################################
# ANALYSIS #
#################################################
data <- read.csv("Data/data.csv")
native_only <- data %>%
filter(AmIAKN == "Yes")
non_native <- data %>%
... |
#' NMR spectra of urine sample of rats with bariatric surgery. A complete description of the dataset can be found here: https://www.frontiersin.org/articles/10.3389/fmicb.2011.00183
#'
#' The data set contains 59 nmr spectra of length 4582 It includes metadata (425 exprimental parameters)
#'
#' @format A data frame wit... | /R/dataset_bariatricRat.binned.5.R | no_license | jwist/hastaLaVista | R | false | false | 542 | r | #' NMR spectra of urine sample of rats with bariatric surgery. A complete description of the dataset can be found here: https://www.frontiersin.org/articles/10.3389/fmicb.2011.00183
#'
#' The data set contains 59 nmr spectra of length 4582 It includes metadata (425 exprimental parameters)
#'
#' @format A data frame wit... |
\name{compute.threshold.AROC.bnp}
\alias{compute.threshold.AROC.bnp}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{
AROC-based threshold values.
}
\description{
Estimates AROC-based threshold values using the nonparametric Bayesian approach proposed by Inacio de Carvalho and Rodriguez-Alvarez (2... | /man/compute.threshold.AROC.bnp.Rd | no_license | cran/AROC | R | false | false | 3,909 | rd | \name{compute.threshold.AROC.bnp}
\alias{compute.threshold.AROC.bnp}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{
AROC-based threshold values.
}
\description{
Estimates AROC-based threshold values using the nonparametric Bayesian approach proposed by Inacio de Carvalho and Rodriguez-Alvarez (2... |
##
## nsga2.R - Interface to nsga2.c
##
## Authors:
## Heike Trautmann <trautmann@statistik.uni-dortmund.de>
## Detlef Steuer <detlef.steuer@hsu-hamburg.de>
## Olaf Mersmann <olafm@statistik.uni-dortmund.de>
##
nsga2 <- function(fn, idim, odim, ...,
constraints=NULL, cdim=0,
... | /mco/R/nsga2.R | no_license | ingted/R-Examples | R | false | false | 3,611 | r | ##
## nsga2.R - Interface to nsga2.c
##
## Authors:
## Heike Trautmann <trautmann@statistik.uni-dortmund.de>
## Detlef Steuer <detlef.steuer@hsu-hamburg.de>
## Olaf Mersmann <olafm@statistik.uni-dortmund.de>
##
nsga2 <- function(fn, idim, odim, ...,
constraints=NULL, cdim=0,
... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/stat-summary.r
\name{stat_summary}
\alias{stat_summary}
\title{Summarise y values at every unique x.}
\usage{
stat_summary(mapping = NULL, data = NULL, geom = "pointrange",
position = "identity", ...)
}
\arguments{
\item{mapping}{The aesthe... | /man/stat_summary.Rd | no_license | cattapre/ggplot2.SparkR | R | false | true | 5,290 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/stat-summary.r
\name{stat_summary}
\alias{stat_summary}
\title{Summarise y values at every unique x.}
\usage{
stat_summary(mapping = NULL, data = NULL, geom = "pointrange",
position = "identity", ...)
}
\arguments{
\item{mapping}{The aesthe... |
library(variancePartition)
library(BiocParallel)
setwd("~/Documents/Batcave/GEO/ccdata/data-raw/")
pdata <- readRDS('cmap_es/pdata.rds')
all_exprs <- readRDS('cmap_es/all_exprs.rds')
# mixed effect model ---
pdata$platform <- factor(platform)
pdata$cell <- factor(pdata$cell)
pdata$batch <- factor(pdata$batch)
pdata$t... | /data-raw/cmap_es/2b-setup_dream.R | no_license | alexvpickering/ccdata | R | false | false | 3,449 | r | library(variancePartition)
library(BiocParallel)
setwd("~/Documents/Batcave/GEO/ccdata/data-raw/")
pdata <- readRDS('cmap_es/pdata.rds')
all_exprs <- readRDS('cmap_es/all_exprs.rds')
# mixed effect model ---
pdata$platform <- factor(platform)
pdata$cell <- factor(pdata$cell)
pdata$batch <- factor(pdata$batch)
pdata$t... |
.assign.synergy <-
function(all_data, nest_data = F, return_wide = F) {
result_types <-
all_data$typeResult %>% unique()
result_types %>%
walk(function(result_type){
table_name <-
glue::glue("dataSynergy{str_to_title(result_type)}") %>%
as.character()
df_result... | /R/synergy.R | no_license | franckess/nbastatR | R | false | false | 8,668 | r | .assign.synergy <-
function(all_data, nest_data = F, return_wide = F) {
result_types <-
all_data$typeResult %>% unique()
result_types %>%
walk(function(result_type){
table_name <-
glue::glue("dataSynergy{str_to_title(result_type)}") %>%
as.character()
df_result... |
rankhospital <- function(state, outcome, num = "best") {
## Read outcome data
data<-read.csv("outcome-of-care-measures.csv", colClasses = "character",na.strings="Not Available")
## Check that state and outcome are valid
validNames = c("heart attack","heart failure","pneumonia")
if (!outcome %in... | /2. Programming R/4/rankhospital.R | no_license | gravialex/Coursera-Data-Scientist | R | false | false | 1,539 | r | rankhospital <- function(state, outcome, num = "best") {
## Read outcome data
data<-read.csv("outcome-of-care-measures.csv", colClasses = "character",na.strings="Not Available")
## Check that state and outcome are valid
validNames = c("heart attack","heart failure","pneumonia")
if (!outcome %in... |
#' Filter Corpus
#'
#' A function that removes all occurances from a given list of words from each (.txt) file in ipath.
#' Generally used after some analysis of the summary_corpus results. To remove the most and least frequent
#' terms. Handles each file in the ipath in parallel over the number of cores specified. Ru... | /R/filter_corpus.R | no_license | avkoehl/textprocessingDSI | R | false | false | 1,836 | r | #' Filter Corpus
#'
#' A function that removes all occurances from a given list of words from each (.txt) file in ipath.
#' Generally used after some analysis of the summary_corpus results. To remove the most and least frequent
#' terms. Handles each file in the ipath in parallel over the number of cores specified. Ru... |
## Course 3 Project
## Step 1: Download the data files
## Get required packages and set the Directory
install.packages("data.table")
install.packages("reshape2")
library(data.table)
library(reshape2)
setwd("C:/Giri/RProgramming/Courseera/Course3")
path <- getwd()
## Download the required data for analysis
... | /run_analysis.R | no_license | Giridash/GetCleanData | R | false | false | 4,549 | r | ## Course 3 Project
## Step 1: Download the data files
## Get required packages and set the Directory
install.packages("data.table")
install.packages("reshape2")
library(data.table)
library(reshape2)
setwd("C:/Giri/RProgramming/Courseera/Course3")
path <- getwd()
## Download the required data for analysis
... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/rm.R
\name{step_rm}
\alias{step_rm}
\alias{tidy.step_rm}
\title{General Variable Filter}
\usage{
step_rm(recipe, ..., role = NA, trained = FALSE, removals = NULL,
skip = FALSE, id = rand_id("rm"))
\method{tidy}{step_rm}(x, ...)
}
\argument... | /man/step_rm.Rd | no_license | ewv88/recipes | R | false | true | 2,431 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/rm.R
\name{step_rm}
\alias{step_rm}
\alias{tidy.step_rm}
\title{General Variable Filter}
\usage{
step_rm(recipe, ..., role = NA, trained = FALSE, removals = NULL,
skip = FALSE, id = rand_id("rm"))
\method{tidy}{step_rm}(x, ...)
}
\argument... |
#position of landmarks
land_x <- c(1,2,2.5)
land_y <- c(1.5,1.5,0.7)
#situation in t-1: position, landmarks, and distance between pos and landmarks
plot(0,0,
main = "state t-1",
col="red",
type = "p",
xlab="x",
ylab="y",
xlim = c(-0.5,3),
ylim = c(-0.5,2),
pch=19,
cex = 2,... | /data-cleaning/plot-second-milestone.R | permissive | YutingYao/DBPro-EKF-SLAM | R | false | false | 1,473 | r | #position of landmarks
land_x <- c(1,2,2.5)
land_y <- c(1.5,1.5,0.7)
#situation in t-1: position, landmarks, and distance between pos and landmarks
plot(0,0,
main = "state t-1",
col="red",
type = "p",
xlab="x",
ylab="y",
xlim = c(-0.5,3),
ylim = c(-0.5,2),
pch=19,
cex = 2,... |
library(aroma.affymetrix)
### Name: SnpPlm
### Title: The SnpPlm interface class
### Aliases: SnpPlm
### Keywords: classes
### ** Examples
for (zzz in 0) {
# Setup verbose output
verbose <- Arguments$getVerbose(-2)
timestampOn(verbose)
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Define... | /data/genthat_extracted_code/aroma.affymetrix/examples/SnpPlm.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 2,707 | r | library(aroma.affymetrix)
### Name: SnpPlm
### Title: The SnpPlm interface class
### Aliases: SnpPlm
### Keywords: classes
### ** Examples
for (zzz in 0) {
# Setup verbose output
verbose <- Arguments$getVerbose(-2)
timestampOn(verbose)
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Define... |
## First get data. Not using nrow and skip as it messes with dataframe column names
df1<-read.table("household_power_consumption.txt",header=T,sep=";",na.strings="?")
df1$Date<-strptime(paste(df1$Date,df1$Time),"%d/%m/%Y %H:%M:%S")
df<-df1[df1$Date<strptime("2007-02-03","%Y-%m-%d"),-2]
rm(df1) ## Remove memory intensiv... | /plot4.R | no_license | sharath333/ExData_Plotting1 | R | false | false | 1,314 | r | ## First get data. Not using nrow and skip as it messes with dataframe column names
df1<-read.table("household_power_consumption.txt",header=T,sep=";",na.strings="?")
df1$Date<-strptime(paste(df1$Date,df1$Time),"%d/%m/%Y %H:%M:%S")
df<-df1[df1$Date<strptime("2007-02-03","%Y-%m-%d"),-2]
rm(df1) ## Remove memory intensiv... |
# Exercise 1: writing and executing functions
# Write a function `AddThree` that adds 3 to an input value
AddThree <- function(num){
return(num + 3)
}
# Create a variable `ten` by passing 7 to your `AddThree` function
ten <- AddThree(7)
# Write a function `FeetToMeters` that converts from feet to meters
FeetToMete... | /exercise-1/exercise.R | permissive | KyleAvalani/ch6-functions | R | false | false | 604 | r | # Exercise 1: writing and executing functions
# Write a function `AddThree` that adds 3 to an input value
AddThree <- function(num){
return(num + 3)
}
# Create a variable `ten` by passing 7 to your `AddThree` function
ten <- AddThree(7)
# Write a function `FeetToMeters` that converts from feet to meters
FeetToMete... |
library(gstat)
### Name: ncp.grid
### Title: Grid for the NCP, the Dutch part of the North Sea
### Aliases: ncp.grid
### Keywords: datasets
### ** Examples
data(ncp.grid)
summary(ncp.grid)
| /data/genthat_extracted_code/gstat/examples/ncp.grid.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 196 | r | library(gstat)
### Name: ncp.grid
### Title: Grid for the NCP, the Dutch part of the North Sea
### Aliases: ncp.grid
### Keywords: datasets
### ** Examples
data(ncp.grid)
summary(ncp.grid)
|
### Numerical gradient====
grad <- function(mod, par, ..., Interval=1e-6) {
mat <- matrix(par, nrow=length(par), ncol=length(par))
for (i in 1:ncol(mat)) {
mat[i,i] <- par[i] + Interval
}
df <- vector("numeric", length=length(par))
f_x <- mod(par, ...)
for (i in 1:ncol(mat)) {
df[i] <- (mo... | /R/algorithms.R | no_license | cran/optimg | R | false | false | 10,029 | r | ### Numerical gradient====
grad <- function(mod, par, ..., Interval=1e-6) {
mat <- matrix(par, nrow=length(par), ncol=length(par))
for (i in 1:ncol(mat)) {
mat[i,i] <- par[i] + Interval
}
df <- vector("numeric", length=length(par))
f_x <- mod(par, ...)
for (i in 1:ncol(mat)) {
df[i] <- (mo... |
#' Gets starting state for scenario
#'
#' @param parameters base model parameters
#' @param starting_conditions a list specifying total_prevalence, total_population, cumulative_incidence, and proportion_vaccinated
#' @param scenario.specs a list which contains a strains.list which is a list of streans, each specifying
... | /HutchCOVID/R/get_starting_state_from_scenario.R | no_license | FredHutch/COVID_modeling_schools | R | false | false | 1,287 | r | #' Gets starting state for scenario
#'
#' @param parameters base model parameters
#' @param starting_conditions a list specifying total_prevalence, total_population, cumulative_incidence, and proportion_vaccinated
#' @param scenario.specs a list which contains a strains.list which is a list of streans, each specifying
... |
shinyUI(navbarPage("Exponential Distribution Simulation Navbar!",
tabPanel("Plot",
sidebarLayout(
sidebarPanel(
h2('Exponential Distribution Simulation Settings'),
sliderInput('lambda', 'Numeric input, labeled lambda', 0.05, min = 0.05, max = 1, step = 0.05),
numericInput('popSize', "Popula... | /ui.r | no_license | richardsun-voyager/ExponentialDistributionApp | R | false | false | 1,108 | r | shinyUI(navbarPage("Exponential Distribution Simulation Navbar!",
tabPanel("Plot",
sidebarLayout(
sidebarPanel(
h2('Exponential Distribution Simulation Settings'),
sliderInput('lambda', 'Numeric input, labeled lambda', 0.05, min = 0.05, max = 1, step = 0.05),
numericInput('popSize', "Popula... |
## ----setup, include = FALSE----------------------------------------------
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>"
)
## ------------------------------------------------------------------------
library(texblocks)
library(texPreview)
## ----include=FALSE---------------------------------------------... | /vignettes/aesthetics.R | permissive | yonicd/texblocks | R | false | false | 2,051 | r | ## ----setup, include = FALSE----------------------------------------------
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>"
)
## ------------------------------------------------------------------------
library(texblocks)
library(texPreview)
## ----include=FALSE---------------------------------------------... |
####### task ############
## data cleaning and exploration
## wilcox testgg
library(readr)
library(ggplot2)
library(tidyverse)
library(rcompanion)
usertype_revenue <- read_csv("Downloads/R_shiny_app_GoogleTrends/Seleted dataset/Data_Usertype_Revenue.csv",
col_types = cols(Revenue... | /Usertype_Revenue_data_wraggling.R | no_license | agbleze/R_shiny_app_GoogleTrends | R | false | false | 5,965 | r | ####### task ############
## data cleaning and exploration
## wilcox testgg
library(readr)
library(ggplot2)
library(tidyverse)
library(rcompanion)
usertype_revenue <- read_csv("Downloads/R_shiny_app_GoogleTrends/Seleted dataset/Data_Usertype_Revenue.csv",
col_types = cols(Revenue... |
# Following two functions will calculate and cache the inverse of a matrix at its first use. When we need it again, it can be looked up in the cache rather than recomputed.
#################################################################################
# This function creates a special matrix object that can cache... | /cachematrix.R | no_license | jairajsingh/ProgrammingAssignment2 | R | false | false | 1,611 | r | # Following two functions will calculate and cache the inverse of a matrix at its first use. When we need it again, it can be looked up in the cache rather than recomputed.
#################################################################################
# This function creates a special matrix object that can cache... |
#' De-identify data through encrypting text columns, grouping rare values, and,
#' aggregating numeric or date columns.
#'
#'
#' @param data
#' A data.frame with the data you want to de-identify.
#' @param cols_to_encrypt
#' A string or vector of strings with the columns that you want to encrypt
#' using the `seed_ciph... | /R/deidentify.R | permissive | seathebass/deidentify | R | false | false | 5,648 | r | #' De-identify data through encrypting text columns, grouping rare values, and,
#' aggregating numeric or date columns.
#'
#'
#' @param data
#' A data.frame with the data you want to de-identify.
#' @param cols_to_encrypt
#' A string or vector of strings with the columns that you want to encrypt
#' using the `seed_ciph... |
# Plot4 : plot 4 different graphs on 2 rows x 2 column matrix
#setup working directory
setwd("~/GitHub/ExData_Plotting1/Plot2.R")
#Read the data in table format and store it in to dataset variable
dataset <- read.table("household_power_consumption.txt",header = TRUE, sep=";",na.strings = "?")
# Get the subset from... | /Plot4.R | no_license | Ruchipatel91/ExData_Plotting1 | R | false | false | 1,648 | r |
# Plot4 : plot 4 different graphs on 2 rows x 2 column matrix
#setup working directory
setwd("~/GitHub/ExData_Plotting1/Plot2.R")
#Read the data in table format and store it in to dataset variable
dataset <- read.table("household_power_consumption.txt",header = TRUE, sep=";",na.strings = "?")
# Get the subset from... |
\name{fast.geomorph.compare.multi.evol.rates}
\alias{fast.geomorph.compare.multi.evol.rates}
\title{
Fast covariance-based implementations of distance-based methods
}
\description{
The functions \code{fast.geomorph.compare.evol.rates}, \code{fast.geomorph.compare.multi.evol.rates}, \code{fast.geomorph.phylo.integ... | /man/fast.geomorph.compare.multi.evol.rates.Rd | no_license | cran/phylocurve | R | false | false | 3,024 | rd | \name{fast.geomorph.compare.multi.evol.rates}
\alias{fast.geomorph.compare.multi.evol.rates}
\title{
Fast covariance-based implementations of distance-based methods
}
\description{
The functions \code{fast.geomorph.compare.evol.rates}, \code{fast.geomorph.compare.multi.evol.rates}, \code{fast.geomorph.phylo.integ... |
\name{head}
\alias{head}
\title{Obtains the first rows of an H2O parsed data object
}
\description{
Obtains the first rows of an H2O parsed data object
}
\usage{
head(x, ...)
}
%- maybe also 'usage' for other objects documented here.
\arguments{
\item{x}{An H2O parsed data object
}
\item{\dots}{The number of rows t... | /R/h2oRClient-package/man/head.Rd | permissive | cloudtrends/h2o | R | false | false | 820 | rd | \name{head}
\alias{head}
\title{Obtains the first rows of an H2O parsed data object
}
\description{
Obtains the first rows of an H2O parsed data object
}
\usage{
head(x, ...)
}
%- maybe also 'usage' for other objects documented here.
\arguments{
\item{x}{An H2O parsed data object
}
\item{\dots}{The number of rows t... |
#' @include Gap_filling.R
NULL
#' @import progress
#' @import data.table
#' @importFrom tools file_path_sans_ext
#' @importFrom xcms xcmsRaw
#' @importFrom xcms rawEIC
NULL
#' @title Fill MS-gaps using SAX
#'
#' @description Function that fills gaps utilizing SAX (Symbol Aggregate approXimation)
#'
#' @param peak_t... | /R/Gap_filling.R | no_license | oolonek/SAX_Gap_Filling | R | false | false | 17,895 | r | #' @include Gap_filling.R
NULL
#' @import progress
#' @import data.table
#' @importFrom tools file_path_sans_ext
#' @importFrom xcms xcmsRaw
#' @importFrom xcms rawEIC
NULL
#' @title Fill MS-gaps using SAX
#'
#' @description Function that fills gaps utilizing SAX (Symbol Aggregate approXimation)
#'
#' @param peak_t... |
pbart = function(x.train, y.train, x.test=matrix(0.0,0,0),
sparse=FALSE, theta=0, omega=1,
a=0.5, b=1, augment=FALSE, rho=NULL,
xinfo=matrix(0.0,0,0), numcut=100L,
usequants=FALSE, cont=FALSE, rm.const=TRUE,
grp = NULL, xnames = NULL, ... | /R/pbart.R | no_license | chujiluo/BNPqte | R | false | false | 8,115 | r | pbart = function(x.train, y.train, x.test=matrix(0.0,0,0),
sparse=FALSE, theta=0, omega=1,
a=0.5, b=1, augment=FALSE, rho=NULL,
xinfo=matrix(0.0,0,0), numcut=100L,
usequants=FALSE, cont=FALSE, rm.const=TRUE,
grp = NULL, xnames = NULL, ... |
\name{eVenn-package}
\alias{eVenn-package}
\alias{eVenn}
\docType{package}
\title{
A Powerful Tool to Quickly Compare Huge Lists and Draw Venn Diagrams
}
\description{
Compare lists (from 2 to infinite) and plot the results in a Venn diagram if (N<=4) with regulation details. It allows to produce a complete annotated f... | /man/eVenn-package.Rd | no_license | NicolasCagnard/eVenn_v2.2.1 | R | false | false | 1,896 | rd | \name{eVenn-package}
\alias{eVenn-package}
\alias{eVenn}
\docType{package}
\title{
A Powerful Tool to Quickly Compare Huge Lists and Draw Venn Diagrams
}
\description{
Compare lists (from 2 to infinite) and plot the results in a Venn diagram if (N<=4) with regulation details. It allows to produce a complete annotated f... |
### iUTAH GAMUT Aquatic Station
### Grab Sample download
### Version 1.1
### Written by: Erin Fleming Jones, contact at erinfjones3@gmail.com
### Last updated: 4/23/2017
setwd("~/Box Sync/BYU/metagenomics")
####NOTES: Check ARBR gage code
## Load packages ##
library("devtools")
library("plyr")
Sys.timezone()
l... | /GAMUTNov14_nonitrate.R | no_license | erinfjones/GAMUTdownload | R | false | false | 51,741 | r | ### iUTAH GAMUT Aquatic Station
### Grab Sample download
### Version 1.1
### Written by: Erin Fleming Jones, contact at erinfjones3@gmail.com
### Last updated: 4/23/2017
setwd("~/Box Sync/BYU/metagenomics")
####NOTES: Check ARBR gage code
## Load packages ##
library("devtools")
library("plyr")
Sys.timezone()
l... |
library(readr)
library(dplyr)
library(tidyr)
library(usmap)
library(maptools)
library(ggplot2)
library(stringr)
seg_loc <- read_csv("SegregationLocation.csv")
hcrimes <- read_csv("HateCrimes.csv")
hcrimes$State <- as.factor(hcrimes$State)
hcrimes$Agency <- as.factor(hcrimes$Agency)
hcrimes$Agency_Type <-... | /Background_Code/ShinyData.R | no_license | mahatfield/HateCrimes | R | false | false | 17,000 | r | library(readr)
library(dplyr)
library(tidyr)
library(usmap)
library(maptools)
library(ggplot2)
library(stringr)
seg_loc <- read_csv("SegregationLocation.csv")
hcrimes <- read_csv("HateCrimes.csv")
hcrimes$State <- as.factor(hcrimes$State)
hcrimes$Agency <- as.factor(hcrimes$Agency)
hcrimes$Agency_Type <-... |
# Make also private functions available
kwb.utils::assignPackageObjects("kwb.nextcloud")
# Are we the test user?
nextcloud_user()
# Ok, we seem to be the test user, let's mess around!
# List the files and folders on the main level
list_files()
# Get the file and folder properties
file_info <- list_files(full_info =... | /R/.test_put-delete.R | permissive | KWB-R/kwb.nextcloud | R | false | false | 2,435 | r | # Make also private functions available
kwb.utils::assignPackageObjects("kwb.nextcloud")
# Are we the test user?
nextcloud_user()
# Ok, we seem to be the test user, let's mess around!
# List the files and folders on the main level
list_files()
# Get the file and folder properties
file_info <- list_files(full_info =... |
library(mtk)
### Name: mtkMorrisAnalyser
### Title: The constructor of the class 'mtkMorrisAnalyser'
### Aliases: mtkMorrisAnalyser
### ** Examples
## Sensitivity analysis of the "Ishigami" model with the "Morris" method
# Generate the factors
data(Ishigami.factors)
# Build the processes and workflow:
# ... | /data/genthat_extracted_code/mtk/examples/mtkMorrisAnalyser.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 862 | r | library(mtk)
### Name: mtkMorrisAnalyser
### Title: The constructor of the class 'mtkMorrisAnalyser'
### Aliases: mtkMorrisAnalyser
### ** Examples
## Sensitivity analysis of the "Ishigami" model with the "Morris" method
# Generate the factors
data(Ishigami.factors)
# Build the processes and workflow:
# ... |
## Reading the data file downloaded and extracted from
## https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip
power_cons <- read.table("./household_power_consumption.txt", header=TRUE, sep=";", stringsAsFactors=FALSE, na.strings="?")
plot_data <- subset(power_cons, power_cons$Date =... | /Plot3.R | no_license | Channabasavaraj/ExData_Plotting1 | R | false | false | 1,095 | r | ## Reading the data file downloaded and extracted from
## https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip
power_cons <- read.table("./household_power_consumption.txt", header=TRUE, sep=";", stringsAsFactors=FALSE, na.strings="?")
plot_data <- subset(power_cons, power_cons$Date =... |
#Set working directory
dirPath<-"/Users/MaxTan/Documents/CU_16spring/EDAV/assign1"
setwd(dirPath)
filename<-"Survey+Response.xlsx"
source("tidydata.R")
df<-tidydata(filename)
source("GenderProgramPlot.R")
GenderProgramPlot(df)
source("TextEditorProgramPlot.R")
TextEditorProgramPlot(df)
source("ToolScoreProgramPlot.... | /Main.R | no_license | MakarAl/EDAV_Project_Class | R | false | false | 468 | r | #Set working directory
dirPath<-"/Users/MaxTan/Documents/CU_16spring/EDAV/assign1"
setwd(dirPath)
filename<-"Survey+Response.xlsx"
source("tidydata.R")
df<-tidydata(filename)
source("GenderProgramPlot.R")
GenderProgramPlot(df)
source("TextEditorProgramPlot.R")
TextEditorProgramPlot(df)
source("ToolScoreProgramPlot.... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/frauddetector_operations.R
\name{frauddetector_create_variable}
\alias{frauddetector_create_variable}
\title{Creates a variable}
\usage{
frauddetector_create_variable(
name,
dataType,
dataSource,
defaultValue,
description = NULL,
... | /cran/paws.machine.learning/man/frauddetector_create_variable.Rd | permissive | paws-r/paws | R | false | true | 1,578 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/frauddetector_operations.R
\name{frauddetector_create_variable}
\alias{frauddetector_create_variable}
\title{Creates a variable}
\usage{
frauddetector_create_variable(
name,
dataType,
dataSource,
defaultValue,
description = NULL,
... |
library(dplyr)
library(ggplot2)
library(gridExtra)
library(ggpubr)
library(data.table)
library(reshape2)
library(knitr)
library(cowplot)
mutate_TB<-function(df){
df$disease<-paste(df$TB, df$SM, sep=" ")
df$disease<-factor(df$disease, levels=c("HC X", "HC SM", "LTBI X", "LTBI SM", "TB X", "TB SM"))
df$TB<-g... | /plot_functions.R | no_license | tarynam/random-code | R | false | false | 18,018 | r | library(dplyr)
library(ggplot2)
library(gridExtra)
library(ggpubr)
library(data.table)
library(reshape2)
library(knitr)
library(cowplot)
mutate_TB<-function(df){
df$disease<-paste(df$TB, df$SM, sep=" ")
df$disease<-factor(df$disease, levels=c("HC X", "HC SM", "LTBI X", "LTBI SM", "TB X", "TB SM"))
df$TB<-g... |
# - source all the tabs -
tabpath <- "./Tabs_ui"
source(file.path(tabpath, "html_styles_ui.R"))
source(file.path(tabpath, "Tab01_ui.R"))
# --
ui <- fluidPage(
html_styles,
Tab01
) | /learn/Learn_ui.R | no_license | TBrach/shiny_apps | R | false | false | 198 | r | # - source all the tabs -
tabpath <- "./Tabs_ui"
source(file.path(tabpath, "html_styles_ui.R"))
source(file.path(tabpath, "Tab01_ui.R"))
# --
ui <- fluidPage(
html_styles,
Tab01
) |
#Pacchetti
library(bsts)
library(chron)
library(tidyverse)
library(data.table)
library(dplyr)
library(forecast)
library(tseries)
library(rjags)
library(coda)
library(plotrix)
#Dataset
load("../../Dataset_pronti/weather_temp.RData")
load("../../Dataset_pronti/train.RData")
key=read.table('../../Data/key.csv',sep=',... | /03. Univariate models/AR with JAGS/AR_model_long.R | no_license | fmacca/bayesian-sales-in-stormy-weather | R | false | false | 9,287 | r |
#Pacchetti
library(bsts)
library(chron)
library(tidyverse)
library(data.table)
library(dplyr)
library(forecast)
library(tseries)
library(rjags)
library(coda)
library(plotrix)
#Dataset
load("../../Dataset_pronti/weather_temp.RData")
load("../../Dataset_pronti/train.RData")
key=read.table('../../Data/key.csv',sep=',... |
library(data.table)
plot2 <- function(){
powercon =read.table("./data/household_power_consumption.txt", header = TRUE, sep = ";",stringsAsFactors=F,na.strings=c("?","NA","N/A",""))
#powercon =fread("./data/household_power_consumption.txt", header = TRUE, sep = ";",
# stringsAsFactors=FALSE,
#... | /plort2.R | no_license | kennethchung/HopkinsDataScience | R | false | false | 994 | r |
library(data.table)
plot2 <- function(){
powercon =read.table("./data/household_power_consumption.txt", header = TRUE, sep = ";",stringsAsFactors=F,na.strings=c("?","NA","N/A",""))
#powercon =fread("./data/household_power_consumption.txt", header = TRUE, sep = ";",
# stringsAsFactors=FALSE,
#... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.