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 |
|---|---|---|---|---|---|---|---|---|---|
# Esly russkie bukvy ne otobrajautsa: File -> Reopen with encoding... UTF-8
# Используйте UTF-8 как кодировку по умолчанию!
# Установить кодировку в RStudio: Tools -> Global Options -> General,
# Default text encoding: UTF-8
# Аналитический пакет R: Занятие 3
# Часть 1: Графические системы R --------------... | /lab_2-3-2019_before.R | no_license | Anastasia1706/practice2_2019 | R | false | false | 23,114 | r | # Esly russkie bukvy ne otobrajautsa: File -> Reopen with encoding... UTF-8
# Используйте UTF-8 как кодировку по умолчанию!
# Установить кодировку в RStudio: Tools -> Global Options -> General,
# Default text encoding: UTF-8
# Аналитический пакет R: Занятие 3
# Часть 1: Графические системы R --------------... |
#' Set Drill SYSTEM or SESSION options
#'
#' Helper function to make it more R-like to set Drill SESSION or SYSTEM optons. It
#' handles the conversion of R types (like \code{TRUE}) to SQL types and automatically
#' quotes parameter values (when necessary).
#'
#' If any query errors result, error messages will be prese... | /R/set.R | no_license | psanjib1/sergeant | R | false | false | 4,265 | r | #' Set Drill SYSTEM or SESSION options
#'
#' Helper function to make it more R-like to set Drill SESSION or SYSTEM optons. It
#' handles the conversion of R types (like \code{TRUE}) to SQL types and automatically
#' quotes parameter values (when necessary).
#'
#' If any query errors result, error messages will be prese... |
library(envimaR)
root_folder = alternativeEnvi(root_folder = "~/edu/mpg-envinsys-plygrnd",
alt_env_id = "COMPUTERNAME",
alt_env_value = "PCRZP",
alt_env_root_folder = "F:\\BEN\\edu")
source(file.path(root_folder, "/mpg-envinfosy... | /src/2_05_Tree_Species_Prediction.R | no_license | BeNrn/RemoteSensing_Repository | R | false | false | 3,028 | r | library(envimaR)
root_folder = alternativeEnvi(root_folder = "~/edu/mpg-envinsys-plygrnd",
alt_env_id = "COMPUTERNAME",
alt_env_value = "PCRZP",
alt_env_root_folder = "F:\\BEN\\edu")
source(file.path(root_folder, "/mpg-envinfosy... |
#### Define new generics from base R ####
## -------------------------------------
setGeneric("as.matrix")
setGeneric("as.array")
setGeneric("apply", signature="X")
setGeneric("scale", signature="x")
setGeneric("levels")
setGeneric("levels<-")
setGeneric("Encoding")
setGeneric("Encoding<-")
setGeneric("crossprod"... | /R/matterGenerics.R | no_license | michbur/matter | R | false | false | 3,482 | r |
#### Define new generics from base R ####
## -------------------------------------
setGeneric("as.matrix")
setGeneric("as.array")
setGeneric("apply", signature="X")
setGeneric("scale", signature="x")
setGeneric("levels")
setGeneric("levels<-")
setGeneric("Encoding")
setGeneric("Encoding<-")
setGeneric("crossprod"... |
context("Boxplot")
# thanks wch for providing the test code
test_that("geom_boxplot range includes all outliers", {
dat <- data.frame(x = 1, y = c(-(1:20) ^ 3, (1:20) ^ 3) )
p <- ggplot_build(ggplot(dat, aes(x,y)) + geom_boxplot())
miny <- p$panel$ranges[[1]]$y.range[1]
maxy <- p$panel$ranges[[1]]$y.range[2]
... | /tests/testthat/test-boxplot.r | no_license | lixinyao/ggplot2 | R | false | false | 1,643 | r | context("Boxplot")
# thanks wch for providing the test code
test_that("geom_boxplot range includes all outliers", {
dat <- data.frame(x = 1, y = c(-(1:20) ^ 3, (1:20) ^ 3) )
p <- ggplot_build(ggplot(dat, aes(x,y)) + geom_boxplot())
miny <- p$panel$ranges[[1]]$y.range[1]
maxy <- p$panel$ranges[[1]]$y.range[2]
... |
veg <- read.csv("./Dropbox/ClimVar/DATA/Plant_composition_data/Cover/Cover_CleanedData/ClimVar_2015_species-cover_wide.csv", header = TRUE)
traits <- read.csv("./Dropbox/ClimVar/DATA/Plant_composition_data/Traits/Traits_GHscreening_Lina_Ashley/Combined_GHtraits.csv", header = TRUE)
BNPP <- read.csv("./Dropbox/ClimVar/D... | /Manifesto/Lina/belowground_trait_diversity.R | no_license | HallettLab/usda-climvar | R | false | false | 17,920 | r | veg <- read.csv("./Dropbox/ClimVar/DATA/Plant_composition_data/Cover/Cover_CleanedData/ClimVar_2015_species-cover_wide.csv", header = TRUE)
traits <- read.csv("./Dropbox/ClimVar/DATA/Plant_composition_data/Traits/Traits_GHscreening_Lina_Ashley/Combined_GHtraits.csv", header = TRUE)
BNPP <- read.csv("./Dropbox/ClimVar/D... |
# какие столбцы
# publish: ProductID add_date
# параметры которые нужно передавать
# 1. путь у config
# 2. дата начала
# 3. дата конца
# 4. категирия товаров
# 5. бренд товаров
publishTime <-function(sql)
{
# создаем запрос
queryPublish =paste("select publish.add_date ",
... | /src/new/plotPublishTime.R | no_license | avz-cmf/bigdata | R | false | false | 1,684 | r | # какие столбцы
# publish: ProductID add_date
# параметры которые нужно передавать
# 1. путь у config
# 2. дата начала
# 3. дата конца
# 4. категирия товаров
# 5. бренд товаров
publishTime <-function(sql)
{
# создаем запрос
queryPublish =paste("select publish.add_date ",
... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/PipeOpMissMDA_PCA_MCA_FMAD.R
\name{PipeOpmissMDA_PCA_MCA_FMAD}
\alias{PipeOpmissMDA_PCA_MCA_FMAD}
\alias{PipeOpMissMDA_PCA_MCA_FMAD}
\title{PipeOpmissMDA_PCA_MCA_FMAD}
\description{
Implements PCA, MCA, FMAD methods as mlr3 pipeline, more abo... | /EMMA_package/EMMA/man/PipeOpmissMDA_PCA_MCA_FMAD.Rd | no_license | okcze/EMMA | R | false | true | 4,008 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/PipeOpMissMDA_PCA_MCA_FMAD.R
\name{PipeOpmissMDA_PCA_MCA_FMAD}
\alias{PipeOpmissMDA_PCA_MCA_FMAD}
\alias{PipeOpMissMDA_PCA_MCA_FMAD}
\title{PipeOpmissMDA_PCA_MCA_FMAD}
\description{
Implements PCA, MCA, FMAD methods as mlr3 pipeline, more abo... |
stud = read.csv("students.csv")
View(stud)
#########
### how to perform the multiple regression analysis
#########
#########
### Basic assumptions:
# the relationship between the variables is liniar
# the variables do not present important outliers*
# there is independence of errors*
# there is no important multico... | /R/datamining/intermediate/intermediate_code/lesson17-regression-basics.R | no_license | Amithmg6/FinestStatsModel | R | false | false | 728 | r | stud = read.csv("students.csv")
View(stud)
#########
### how to perform the multiple regression analysis
#########
#########
### Basic assumptions:
# the relationship between the variables is liniar
# the variables do not present important outliers*
# there is independence of errors*
# there is no important multico... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/edfClass.R
\name{create.experimentl}
\alias{create.experimentl}
\title{Create standard zebrafish experiment on server
Using Z10}
\usage{
create.experimentl(
dir,
exper,
saveDir = "/export/valenfs/data/processed_data/experiment_tables_fo... | /ORFikPipeline/man/create.experimentl.Rd | permissive | Roleren/RCode | R | false | true | 1,587 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/edfClass.R
\name{create.experimentl}
\alias{create.experimentl}
\title{Create standard zebrafish experiment on server
Using Z10}
\usage{
create.experimentl(
dir,
exper,
saveDir = "/export/valenfs/data/processed_data/experiment_tables_fo... |
#' Generate summary numbers that indicative of experiment quality
#' Please provide a raw sigset (before any preprocessing). Usually
#' directly from readIDATpair
#'
#' @param sset a \code{SigSet} object
#' @return a sesameQC class object
#' @examples
#' sset <- sesameDataGet('EPIC.1.LNCaP')$sset
#' sesameQC(sset)
#'... | /R/QC.R | permissive | wangdi2014/sesame | R | false | false | 8,983 | r |
#' Generate summary numbers that indicative of experiment quality
#' Please provide a raw sigset (before any preprocessing). Usually
#' directly from readIDATpair
#'
#' @param sset a \code{SigSet} object
#' @return a sesameQC class object
#' @examples
#' sset <- sesameDataGet('EPIC.1.LNCaP')$sset
#' sesameQC(sset)
#'... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/seg_stats.R
\name{qc.from.segstats.tables}
\alias{qc.from.segstats.tables}
\title{Perform data quality check based on a segstats table.}
\usage{
qc.from.segstats.tables(filepath_lh, filepath_rh, ...)
}
\arguments{
\item{filepath_lh}{path to l... | /man/qc.from.segstats.tables.Rd | permissive | dfsp-spirit/fsbrain | R | false | true | 1,170 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/seg_stats.R
\name{qc.from.segstats.tables}
\alias{qc.from.segstats.tables}
\title{Perform data quality check based on a segstats table.}
\usage{
qc.from.segstats.tables(filepath_lh, filepath_rh, ...)
}
\arguments{
\item{filepath_lh}{path to l... |
with(a73b3b108389a4a8ba76f47da80782f33, {ROOT <- 'C:/semoss/semosshome/db/Atadata2__3b3e4a3b-d382-4e98-9950-9b4e8b308c1c/version/dd24a479-55ab-4c37-83f4-a724838001a0';rm(list=ls())}); | /dd24a479-55ab-4c37-83f4-a724838001a0/R/Temp/adnFl2621mLnb.R | no_license | ayanmanna8/test | R | false | false | 183 | r | with(a73b3b108389a4a8ba76f47da80782f33, {ROOT <- 'C:/semoss/semosshome/db/Atadata2__3b3e4a3b-d382-4e98-9950-9b4e8b308c1c/version/dd24a479-55ab-4c37-83f4-a724838001a0';rm(list=ls())}); |
library(shiny)
library(tm)
library(RSpectra)
library(lsa)
library(stringr)
# Load data
covid_df <- readRDS("covid_df.rds")
#tdm <- readRDS("tdm.rds")
#tdm$dimnames$Terms <- readRDS("tdm_dictionary.rds")
#query_matrix <- readRDS("query_matrix.rds")
#lsa <- readRDS("lsa.rds")
#sigma_inverse <- readRDS("sigma_inverse.rds... | /app.R | no_license | bstrain71/covid_navadmins_search | R | false | false | 5,306 | r | library(shiny)
library(tm)
library(RSpectra)
library(lsa)
library(stringr)
# Load data
covid_df <- readRDS("covid_df.rds")
#tdm <- readRDS("tdm.rds")
#tdm$dimnames$Terms <- readRDS("tdm_dictionary.rds")
#query_matrix <- readRDS("query_matrix.rds")
#lsa <- readRDS("lsa.rds")
#sigma_inverse <- readRDS("sigma_inverse.rds... |
#Compiles NO3 data from .xlsx run files
rm(list=ls()) #clear variables
# Source the database functions
source("C:/Users/notter/Google Drive/Randi/Database/R/dbUtil.R")
# Set up objects to locate database. Functions in dbUtil require these to be defined ahead of use.
dbdir="C:/Users/notter/Google Drive/Randi/Database... | /Water/Scripts/compileNO3_20210217.R | no_license | Randinotte/workup2020 | R | false | false | 7,587 | r | #Compiles NO3 data from .xlsx run files
rm(list=ls()) #clear variables
# Source the database functions
source("C:/Users/notter/Google Drive/Randi/Database/R/dbUtil.R")
# Set up objects to locate database. Functions in dbUtil require these to be defined ahead of use.
dbdir="C:/Users/notter/Google Drive/Randi/Database... |
library(lubridate)
library(tidyverse)
load('C:/Users/admin/Desktop/Tesis Maestria/Datos Preparados/PreciosOfertaAgentes2016.RData')
PreciosOfertaAgentes2016Cor <- PreciosOfertaAgentes2016[ , names(PreciosOfertaAgentes2016) %in%
c('CodigoAgente', 'Fecha','PrecioOfertaIdeal... | /Scrips/Correlaciones.R | no_license | JEstebanMejiaV/Sector-Energetico-en-Colombia | R | false | false | 8,122 | r |
library(lubridate)
library(tidyverse)
load('C:/Users/admin/Desktop/Tesis Maestria/Datos Preparados/PreciosOfertaAgentes2016.RData')
PreciosOfertaAgentes2016Cor <- PreciosOfertaAgentes2016[ , names(PreciosOfertaAgentes2016) %in%
c('CodigoAgente', 'Fecha','PrecioOfertaIdeal... |
#setwd("C://DISCO_D//ORGANIZADO//Coursera//__Coursera//08_Data Science Specialization//04_Exploratory Data Analysis//Project_1")
## Get Data
fileURL = "https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip"
download.file(fileURL, "Electric_Power_Consumption.zip")
unzip("Electric_Power... | /plot4.R | no_license | joaomrei/ExData_Plotting1 | R | false | false | 1,768 | r | #setwd("C://DISCO_D//ORGANIZADO//Coursera//__Coursera//08_Data Science Specialization//04_Exploratory Data Analysis//Project_1")
## Get Data
fileURL = "https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip"
download.file(fileURL, "Electric_Power_Consumption.zip")
unzip("Electric_Power... |
#' Loglikelihood adjustments for glm fits
#'
#' In a generalised linear model (glm), the user can choose between a range of
#' distributions of a response \eqn{y}, and can allow for non-linear relations
#' between the mean outcome for a particular combination of covariates \eqn{x},
#' \eqn{E(y_i\mid x_i)=\mu_i}, and th... | /R/glm.R | no_license | cran/chantrics | R | false | false | 7,747 | r | #' Loglikelihood adjustments for glm fits
#'
#' In a generalised linear model (glm), the user can choose between a range of
#' distributions of a response \eqn{y}, and can allow for non-linear relations
#' between the mean outcome for a particular combination of covariates \eqn{x},
#' \eqn{E(y_i\mid x_i)=\mu_i}, and th... |
# Function to nest duplicated columns after multiple data frames are merged.
#
# Args:
# df Data frame of joined data frames with duplicated columns.
# suffixes Character string to match suffixes. E.g., the default "\\.[xy]"
# finds any columns ending with .x or .y
nest_duplicated <- function(df, suffixe... | /R/data_prep/utility_functions.R | no_license | minghao2016/ourworldindata | R | false | false | 1,589 | r | # Function to nest duplicated columns after multiple data frames are merged.
#
# Args:
# df Data frame of joined data frames with duplicated columns.
# suffixes Character string to match suffixes. E.g., the default "\\.[xy]"
# finds any columns ending with .x or .y
nest_duplicated <- function(df, suffixe... |
/R语言统计分析与应用/《R语言统计分析与应用》配套程序/第八章/example8_2.R | no_license | wwjvictor/test-R | R | false | false | 417 | r | ||
## Introduction to R for Data Science
## ══════════════════════════════════════════════════════════════════════════════════
## SESSION 07: PROBABILITY FUNCTIONS IN R
## ══════════════════════════════════════════════════════════════════════════════════
## Autumn/Winter 2016.
## Data Science Serbia @Startit Centre, Savs... | /S07 - Probability Functions in R.R | no_license | radovankavicky/Introduction-to-R-for-Data-Science | R | false | false | 12,638 | r |
## Introduction to R for Data Science
## ══════════════════════════════════════════════════════════════════════════════════
## SESSION 07: PROBABILITY FUNCTIONS IN R
## ══════════════════════════════════════════════════════════════════════════════════
## Autumn/Winter 2016.
## Data Science Serbia @Startit Centre, Savs... |
#' make prediction plots for lm and glm objects using ggformula
#'
#' @param data a data frame, or a fitted model object (from which the data will be extracted)
#'
#' @export
#' @return a data frame with one row, containing the same variables as data, in which each variable takes on its median value (continuous variabl... | /R/get_fixed.R | no_license | stacyderuiter/s245 | R | false | false | 1,808 | r | #' make prediction plots for lm and glm objects using ggformula
#'
#' @param data a data frame, or a fitted model object (from which the data will be extracted)
#'
#' @export
#' @return a data frame with one row, containing the same variables as data, in which each variable takes on its median value (continuous variabl... |
testlist <- list(type = 0L, z = 5.43230922731672e-312)
result <- do.call(esreg::G1_fun,testlist)
str(result) | /esreg/inst/testfiles/G1_fun/libFuzzer_G1_fun/G1_fun_valgrind_files/1609889256-test.R | no_license | akhikolla/updated-only-Issues | R | false | false | 108 | r | testlist <- list(type = 0L, z = 5.43230922731672e-312)
result <- do.call(esreg::G1_fun,testlist)
str(result) |
## This function stores a cache of the inverse of the matrix,
## so after calculating for the first time, there's no need to calculate again.
makeCacheMatrix <- function(x = matrix()) {
m <- NULL
set <- function(y) {
x <<- y
m <<- NULL
}
get <- function() x
setinverse <- function(solve) m <<- solve
... | /cachematrix.R | no_license | darcyoctopus/ProgrammingAssignment2 | R | false | false | 795 | r | ## This function stores a cache of the inverse of the matrix,
## so after calculating for the first time, there's no need to calculate again.
makeCacheMatrix <- function(x = matrix()) {
m <- NULL
set <- function(y) {
x <<- y
m <<- NULL
}
get <- function() x
setinverse <- function(solve) m <<- solve
... |
# Access to Banku Danych Lokalnych
# through the API in http://mojepanstwo.pl/api/!/bdl/!/bdl/!/bdl/series
# is using rjson
getBDLtree <- function(debug = 0, raw = FALSE) {
url <- 'http://api.mojepanstwo.pl/bdl/tree'
document <- fromJSON(file=url, method='C')
if (raw) return(document)
dgs <- lapply(document,... | /R/BankDanychLokalnych.R | no_license | gancedo/SmarterPoland | R | false | false | 3,533 | r | # Access to Banku Danych Lokalnych
# through the API in http://mojepanstwo.pl/api/!/bdl/!/bdl/!/bdl/series
# is using rjson
getBDLtree <- function(debug = 0, raw = FALSE) {
url <- 'http://api.mojepanstwo.pl/bdl/tree'
document <- fromJSON(file=url, method='C')
if (raw) return(document)
dgs <- lapply(document,... |
# Server Code
# Author : Rajasekhar Jetty
library(shiny)
library(ggplot2)
# Define server logic required to draw a histogram
shinyServer(function(input, output) {
# Expression that generates a histogram. The expression is
# wrapped in a call to renderPlot to indicate that:
#
# 1) It is "reactiv... | /Session_2/thirdApp/server.R | no_license | raj2014/UTD_DSC_HANDS_ON | R | false | false | 905 | r | # Server Code
# Author : Rajasekhar Jetty
library(shiny)
library(ggplot2)
# Define server logic required to draw a histogram
shinyServer(function(input, output) {
# Expression that generates a histogram. The expression is
# wrapped in a call to renderPlot to indicate that:
#
# 1) It is "reactiv... |
source("packages.R")
data(neuroblastomaProcessed, package="penaltyLearning")
err.dt <- neuroblastomaProcessed$errors[profile.id==2]
range.vec <- err.dt[, {
l <- c(min.log.lambda, max.log.lambda)
range(l[is.finite(l)])
}]
pred <- seq(range.vec[1]-1, range.vec[2]+1, l=1001)
mynorm <- function(x)1/(1+exp(-10*x))
p... | /figure-ordinal-selection.R | no_license | tdhock/bayesian-labeled-changepoint | R | false | false | 2,048 | r | source("packages.R")
data(neuroblastomaProcessed, package="penaltyLearning")
err.dt <- neuroblastomaProcessed$errors[profile.id==2]
range.vec <- err.dt[, {
l <- c(min.log.lambda, max.log.lambda)
range(l[is.finite(l)])
}]
pred <- seq(range.vec[1]-1, range.vec[2]+1, l=1001)
mynorm <- function(x)1/(1+exp(-10*x))
p... |
testlist <- list(Rext = numeric(0), Rs = numeric(0), Z = numeric(0), alpha = numeric(0), atmp = c(1.1988711311556e-153, 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, ... | /meteor/inst/testfiles/E_Penman/AFL_E_Penman/E_Penman_valgrind_files/1615918568-test.R | no_license | akhikolla/updatedatatype-list3 | R | false | false | 1,238 | r | testlist <- list(Rext = numeric(0), Rs = numeric(0), Z = numeric(0), alpha = numeric(0), atmp = c(1.1988711311556e-153, 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, ... |
\docType{data}
\name{salarios}
\alias{salarios}
\title{Tabla de salarios}
\format{Un data frame con 26.428 filas y 5 columnas
\describe{
\item{anio}{Año}
\item{id_equipo}{ID equipo (factor)}
\item{id_liga}{ID liga (factor)}
\item{id_jugador}{ID del jugador}
\item{salario}{Salario en dólares}
}}
\description{Información... | /man/salarios.rd | permissive | cienciadedatos/datos | R | false | false | 378 | rd | \docType{data}
\name{salarios}
\alias{salarios}
\title{Tabla de salarios}
\format{Un data frame con 26.428 filas y 5 columnas
\describe{
\item{anio}{Año}
\item{id_equipo}{ID equipo (factor)}
\item{id_liga}{ID liga (factor)}
\item{id_jugador}{ID del jugador}
\item{salario}{Salario en dólares}
}}
\description{Información... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/process.R
\name{cortar}
\alias{cortar}
\title{Cortar}
\usage{
cortar(img, x_min = 10, x_max = 180, y_min = 12, y_max = 42)
}
\arguments{
\item{img}{imagem em formato de data.frame com as coluans x, y, r,g, e b}
\item{x_min}{10}
\item{x_max}... | /man/cortar.Rd | no_license | dfalbel/captchaReceita2 | R | false | true | 509 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/process.R
\name{cortar}
\alias{cortar}
\title{Cortar}
\usage{
cortar(img, x_min = 10, x_max = 180, y_min = 12, y_max = 42)
}
\arguments{
\item{img}{imagem em formato de data.frame com as coluans x, y, r,g, e b}
\item{x_min}{10}
\item{x_max}... |
ARGV <- commandArgs(T)
ARGV <- as.numeric(ARGV)
n<- ARGV[1] #which file
max<- ARGV[2] #max length of records
nline<- ARGV[3] #number of records
library(calibrate)
format <- as.numeric(rep(NA,max))
M <- matrix(format,nrow=round(nline/2),ncol = max,byrow=TRUE) #make a matrix
bt <- sample(c(0:(nline-1)),size=round(nline... | /indel/src/compute1.R | no_license | miR172/BioinformaticsProjects | R | false | false | 2,627 | r | ARGV <- commandArgs(T)
ARGV <- as.numeric(ARGV)
n<- ARGV[1] #which file
max<- ARGV[2] #max length of records
nline<- ARGV[3] #number of records
library(calibrate)
format <- as.numeric(rep(NA,max))
M <- matrix(format,nrow=round(nline/2),ncol = max,byrow=TRUE) #make a matrix
bt <- sample(c(0:(nline-1)),size=round(nline... |
project_data <- read.csv("project_data.csv", stringsAsFactors = FALSE)
png("plot1.png")
hist(project_data$Global_active_power,
col = "red", xlab = "Global Active Power (kilowatts)", main = "Global Active Power")
dev.off()
| /plot1.R | no_license | ccowens/ExData_Plotting1 | R | false | false | 228 | r | project_data <- read.csv("project_data.csv", stringsAsFactors = FALSE)
png("plot1.png")
hist(project_data$Global_active_power,
col = "red", xlab = "Global Active Power (kilowatts)", main = "Global Active Power")
dev.off()
|
library(msaenet)
### Name: msaenet
### Title: Multi-Step Adaptive Elastic-Net
### Aliases: msaenet
### ** Examples
dat <- msaenet.sim.gaussian(
n = 150, p = 500, rho = 0.6,
coef = rep(1, 5), snr = 2, p.train = 0.7,
seed = 1001
)
msaenet.fit <- msaenet(
dat$x.tr, dat$y.tr,
alphas = seq(0.2, 0.8, 0.2),
n... | /data/genthat_extracted_code/msaenet/examples/msaenet.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 554 | r | library(msaenet)
### Name: msaenet
### Title: Multi-Step Adaptive Elastic-Net
### Aliases: msaenet
### ** Examples
dat <- msaenet.sim.gaussian(
n = 150, p = 500, rho = 0.6,
coef = rep(1, 5), snr = 2, p.train = 0.7,
seed = 1001
)
msaenet.fit <- msaenet(
dat$x.tr, dat$y.tr,
alphas = seq(0.2, 0.8, 0.2),
n... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/data_structure.R
\name{sv_as_factor.dataframe}
\alias{sv_as_factor.dataframe}
\title{Converts a data.frame to a factor data.frame each var with the.levels level}
\usage{
sv_as_factor.dataframe(data.df, the.levels, be.ordered = TRUE)
}
\argume... | /man/sv_as_factor.dataframe.Rd | no_license | shahryareiv/singleverbr | R | false | true | 439 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/data_structure.R
\name{sv_as_factor.dataframe}
\alias{sv_as_factor.dataframe}
\title{Converts a data.frame to a factor data.frame each var with the.levels level}
\usage{
sv_as_factor.dataframe(data.df, the.levels, be.ordered = TRUE)
}
\argume... |
rm(list=ls())
data_cust2 <- read.csv("data_cust_2-2.csv", header=TRUE)
data_cust_known <- subset(data_cust2, subset=DIVIDED_SET==1) #사기자 여부가 판별된 데이터를 이용해 학습시킴
data_cust_known <- subset(data_cust_known, select=-DIVIDED_SET) #DIVIDED_SET 열 제거
idx <- sample(1:nrow(data_cust_known), nrow(data_cust_known), replace=... | /Lab_2-3.R | no_license | daawonn/R_project | R | false | false | 825 | r | rm(list=ls())
data_cust2 <- read.csv("data_cust_2-2.csv", header=TRUE)
data_cust_known <- subset(data_cust2, subset=DIVIDED_SET==1) #사기자 여부가 판별된 데이터를 이용해 학습시킴
data_cust_known <- subset(data_cust_known, select=-DIVIDED_SET) #DIVIDED_SET 열 제거
idx <- sample(1:nrow(data_cust_known), nrow(data_cust_known), replace=... |
##################################################################################
# NAME: DBSCAN_history.R
# AUTHOUR: Alan Davies
# DATE: 02/12/2017
# INSTITUTION: Interaction Analysis and Modelling Lab (IAM), University of Manchester
# DESCRIPTION:
#
############################... | /DBSCAN_history.R | no_license | IAM-lab/clinical-history | R | false | false | 9,769 | r | ##################################################################################
# NAME: DBSCAN_history.R
# AUTHOUR: Alan Davies
# DATE: 02/12/2017
# INSTITUTION: Interaction Analysis and Modelling Lab (IAM), University of Manchester
# DESCRIPTION:
#
############################... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/imgw_hydro_abbrev.R
\docType{data}
\name{imgw_hydro_abbrev}
\alias{imgw_hydro_abbrev}
\title{Definitions of hydrological parameters used for shortening column names from the danepubliczne.imgw.pl collection}
\format{
The data contains a data.... | /man/imgw_hydro_abbrev.Rd | permissive | Schuch666/climate | R | false | true | 1,094 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/imgw_hydro_abbrev.R
\docType{data}
\name{imgw_hydro_abbrev}
\alias{imgw_hydro_abbrev}
\title{Definitions of hydrological parameters used for shortening column names from the danepubliczne.imgw.pl collection}
\format{
The data contains a data.... |
getLat = function(station){
stationRow = subset(stationData, stopId == station)
#add not found exception!
return(stationRow$lat)
}
getLon = function(station){
stationRow = subset(stationData, stopId == station)
#add not found exception!
return(stationRow$lon)
} | /transitVerification/functions.R | no_license | cllorca1/matsimScaling | R | false | false | 277 | r | getLat = function(station){
stationRow = subset(stationData, stopId == station)
#add not found exception!
return(stationRow$lat)
}
getLon = function(station){
stationRow = subset(stationData, stopId == station)
#add not found exception!
return(stationRow$lon)
} |
testlist <- list(id = NULL, id = NULL, booklet_id = c(8168473L, 2127314835L, 171177770L, -1942759639L, -1815221204L, 601253144L, -804651186L, 2094281728L, 860713787L, -971707632L, -1475044502L, 870040598L, -1182814578L, -1415711445L, 1901326755L, -1882837573L, 1340545259L, 1156041943L, 823641812L, -1106109928L, -10... | /dexterMST/inst/testfiles/is_person_booklet_sorted/AFL_is_person_booklet_sorted/is_person_booklet_sorted_valgrind_files/1615940637-test.R | no_license | akhikolla/updatedatatype-list1 | R | false | false | 826 | r | testlist <- list(id = NULL, id = NULL, booklet_id = c(8168473L, 2127314835L, 171177770L, -1942759639L, -1815221204L, 601253144L, -804651186L, 2094281728L, 860713787L, -971707632L, -1475044502L, 870040598L, -1182814578L, -1415711445L, 1901326755L, -1882837573L, 1340545259L, 1156041943L, 823641812L, -1106109928L, -10... |
# Creating box plots for quantitative variables
# Create data frame "sn" from CSV file w/headers
sn <- read.csv("social_network.csv", header = T)
# Make boxplots of Age and Times using the defaults
boxplot(sn$Age)
# Add title, colors, etc.
boxplot(sn$Age,
col = "beige",
notch = T,
horizontal ... | /R examples/R Simple Training/Example R 03_03.R | no_license | wouldyougo/wouldyougo.github.io | R | false | false | 438 | r | # Creating box plots for quantitative variables
# Create data frame "sn" from CSV file w/headers
sn <- read.csv("social_network.csv", header = T)
# Make boxplots of Age and Times using the defaults
boxplot(sn$Age)
# Add title, colors, etc.
boxplot(sn$Age,
col = "beige",
notch = T,
horizontal ... |
setwd("C:/Users/mhapp/Desktop/AGRO932/")
library(data.table)
library(ggplot2)
library(RColorBrewer)
library(dplyr)
library(ggrepel)
library(hrbrthemes)
Theta_1 <- fread("Data/Theta.HY.sw.txt")
Theta_2 <- fread("Data/Theta.Drought.sw.txt")
Theta_3 <- fread("Data/Theta.Diverse.sw.txt")
colnames(Theta_1) <... | /Scripts/R/Theta.Manhattan.R | no_license | mhapp95/AGRO932-TermProject | R | false | false | 5,047 | r | setwd("C:/Users/mhapp/Desktop/AGRO932/")
library(data.table)
library(ggplot2)
library(RColorBrewer)
library(dplyr)
library(ggrepel)
library(hrbrthemes)
Theta_1 <- fread("Data/Theta.HY.sw.txt")
Theta_2 <- fread("Data/Theta.Drought.sw.txt")
Theta_3 <- fread("Data/Theta.Diverse.sw.txt")
colnames(Theta_1) <... |
% Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/http-post.r
\name{POST}
\alias{POST}
\title{POST file to a server.}
\usage{
POST(url = NULL, config = list(), ..., body = NULL,
encode = c("multipart", "form", "json"), multipart = TRUE,
handle = NULL)
}
\arguments{
\item{url}{the... | /Data Science/Miscellaenous/Misc - httr info/man/POST.Rd | no_license | Mike-Kuklinski/Coursera | R | false | false | 2,923 | rd | % Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/http-post.r
\name{POST}
\alias{POST}
\title{POST file to a server.}
\usage{
POST(url = NULL, config = list(), ..., body = NULL,
encode = c("multipart", "form", "json"), multipart = TRUE,
handle = NULL)
}
\arguments{
\item{url}{the... |
# load packages
# install packages from CRAN
p_needed <- c(
'rmarkdown',
'ggplot2',
'ineq',
'tidyverse',
'readxl',
'reldist',
'reshape2',
'plyr',
'data.table',
'corrplot',
'GGally',
'stargazer',
'caret',
'kableExtra',
'gridExtra',
'qwraps2',
'xtable',
'knitr',
'kableExtra',
... | /packages.R | no_license | brunosj/canada-inequality | R | false | false | 611 | r |
# load packages
# install packages from CRAN
p_needed <- c(
'rmarkdown',
'ggplot2',
'ineq',
'tidyverse',
'readxl',
'reldist',
'reshape2',
'plyr',
'data.table',
'corrplot',
'GGally',
'stargazer',
'caret',
'kableExtra',
'gridExtra',
'qwraps2',
'xtable',
'knitr',
'kableExtra',
... |
\name{pyparpredict}
\alias{pyparpredict}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{Python parallel computation for prediction}
\description{Python parallel computation for prediction by access to server. }
\usage{
pyparpredict(dset, flag = "prefile", nModel = 6, ncore = 6)
}
%- maybe also 'u... | /man/pyparpredict.Rd | no_license | lspatial/sptemUS | R | false | false | 2,139 | rd | \name{pyparpredict}
\alias{pyparpredict}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{Python parallel computation for prediction}
\description{Python parallel computation for prediction by access to server. }
\usage{
pyparpredict(dset, flag = "prefile", nModel = 6, ncore = 6)
}
%- maybe also 'u... |
# Script to create and update model
library(bysykkel)
library(tidyverse)
library(tidymodels)
library(lubridate)
# Collect data from june to current month
cur_month <- lubridate::month(today())
bergen_trips <- map_dfr(9:cur_month, fread_trips_data, year = 2020, city = "Bergen")
trips <- bergen_trips %>%
mutate(hour... | /update_model.R | no_license | andrewaage/bysykkel_ml | R | false | false | 1,589 | r | # Script to create and update model
library(bysykkel)
library(tidyverse)
library(tidymodels)
library(lubridate)
# Collect data from june to current month
cur_month <- lubridate::month(today())
bergen_trips <- map_dfr(9:cur_month, fread_trips_data, year = 2020, city = "Bergen")
trips <- bergen_trips %>%
mutate(hour... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/RcppExports.R
\name{LoggerTime}
\alias{LoggerTime}
\title{Logger class to log the elapsed time}
\format{\code{\link{S4}} object.}
\description{
This class just logs the elapsed time. This should be very handy if one
wants to run the algorithm... | /man/LoggerTime.Rd | permissive | QuayAu/compboost | R | false | true | 1,721 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/RcppExports.R
\name{LoggerTime}
\alias{LoggerTime}
\title{Logger class to log the elapsed time}
\format{\code{\link{S4}} object.}
\description{
This class just logs the elapsed time. This should be very handy if one
wants to run the algorithm... |
# Code placed in this file fill be executed every time the
# lesson is started. Any variables created here will show up in
# the user's working directory and thus be accessible to them
# throughout the lesson.
# swirl_options(swirl_logging = TRUE)
calc_rmse <- function(ytrue, ypred) {
res <- sum((... | /Session_09/initLesson.R | no_license | ahdvnd/cs112-swirl-courses | R | false | false | 375 | r | # Code placed in this file fill be executed every time the
# lesson is started. Any variables created here will show up in
# the user's working directory and thus be accessible to them
# throughout the lesson.
# swirl_options(swirl_logging = TRUE)
calc_rmse <- function(ytrue, ypred) {
res <- sum((... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/enrichment_analysis.R
\name{parseMsigdb}
\alias{parseMsigdb}
\title{parseMsigdb}
\usage{
parseMsigdb()
}
\description{
This function is deprecated. For functional enrichment
analysis, use findEnrichedFunctions.
}
| /man/parseMsigdb.Rd | no_license | BIMSBbioinfo/RCAS | R | false | true | 292 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/enrichment_analysis.R
\name{parseMsigdb}
\alias{parseMsigdb}
\title{parseMsigdb}
\usage{
parseMsigdb()
}
\description{
This function is deprecated. For functional enrichment
analysis, use findEnrichedFunctions.
}
|
## The objective is to create an inverse of a matrix and cahce the same in
## memory. Since the inverse of matrix is a costly operation by saving it in
## cache allows us to reuse the value, without computing it again and again.
## This function will create a cache for a particular matrix as its inverse
makeCacheMat... | /cachematrix.R | no_license | Sara1292/ProgrammingAssignment2 | R | false | false | 1,034 | r | ## The objective is to create an inverse of a matrix and cahce the same in
## memory. Since the inverse of matrix is a costly operation by saving it in
## cache allows us to reuse the value, without computing it again and again.
## This function will create a cache for a particular matrix as its inverse
makeCacheMat... |
rm(list = ls())
setwd("~/Git/paperData/N-2 Repetition Cost Reliability")
source("functions.R")
library(dplyr)
library(ez)
library(ggplot2)
library(moments)
library(tidyr)
library(Hmisc)
library(ppcor)
# make sure the most recent version of trimr is installed
#devtools::install_github("JimGrange/trimr")
library(trim... | /N-2 Repetition Cost Reliability/code.R | no_license | norberello/paperData | R | false | false | 24,605 | r | rm(list = ls())
setwd("~/Git/paperData/N-2 Repetition Cost Reliability")
source("functions.R")
library(dplyr)
library(ez)
library(ggplot2)
library(moments)
library(tidyr)
library(Hmisc)
library(ppcor)
# make sure the most recent version of trimr is installed
#devtools::install_github("JimGrange/trimr")
library(trim... |
## Get data from dataset in working library
## withour string as Factors option I was getting some weird results and treating numerics as factors.
data <- read.table("./household_power_consumption.txt", header = TRUE, sep = ";", stringsAsFactors=FALSE, dec=".")
## convert Date field in to Date data type so that we ca... | /plot3.R | no_license | nangineni/ExData_Plotting1 | R | false | false | 1,433 | r |
## Get data from dataset in working library
## withour string as Factors option I was getting some weird results and treating numerics as factors.
data <- read.table("./household_power_consumption.txt", header = TRUE, sep = ";", stringsAsFactors=FALSE, dec=".")
## convert Date field in to Date data type so that we ca... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/var_error.R
\name{var_error_r}
\alias{var_error_r}
\title{Estimate the error variance of correlations}
\usage{
var_error_r(r, n, correct_bias = TRUE)
}
\arguments{
\item{r}{Vector of correlations.}
\item{n}{Vector of sample sizes.}
\item{co... | /man/var_error_r.Rd | no_license | romainfrancois/psychmeta | R | false | true | 1,199 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/var_error.R
\name{var_error_r}
\alias{var_error_r}
\title{Estimate the error variance of correlations}
\usage{
var_error_r(r, n, correct_bias = TRUE)
}
\arguments{
\item{r}{Vector of correlations.}
\item{n}{Vector of sample sizes.}
\item{co... |
setwd(dirname(rstudioapi::getSourceEditorContext()$path))
# Simulation of a discretized logit model
set.seed(2)
x = matrix(runif(300), nrow = 100, ncol = 3)
cuts = seq(0,1,length.out= 4)
xd = apply(x,2, function(col) as.numeric(cut(col,cuts)))
theta = t(matrix(c(0,0,0,2,2,2,-2,-2,-2),ncol=3,nrow=3))
log_odd = rowSu... | /R_CODE_FIGURES/appendix/animation_disc_SEM/glmdisc_SEM_figures.R | permissive | Sandy4321/manuscrit_these | R | false | false | 10,996 | r |
setwd(dirname(rstudioapi::getSourceEditorContext()$path))
# Simulation of a discretized logit model
set.seed(2)
x = matrix(runif(300), nrow = 100, ncol = 3)
cuts = seq(0,1,length.out= 4)
xd = apply(x,2, function(col) as.numeric(cut(col,cuts)))
theta = t(matrix(c(0,0,0,2,2,2,-2,-2,-2),ncol=3,nrow=3))
log_odd = rowSu... |
#' @name kobo_left_align
#' @rdname kobo_left_align
#' @title UNHCR ggplot2 theme
#'
#' @description Left align chart title and subtitle on a ggplot2
#'
#' @return Return better chart
#'
#' @author Edouard Legoupil - with inspiration from bbc
#'
#' @param plot_name ggplot2 object
#' @param pieces plot labels to align
... | /R/kobo_left_align.R | no_license | unhcr/koboloadeR | R | false | false | 588 | r | #' @name kobo_left_align
#' @rdname kobo_left_align
#' @title UNHCR ggplot2 theme
#'
#' @description Left align chart title and subtitle on a ggplot2
#'
#' @return Return better chart
#'
#' @author Edouard Legoupil - with inspiration from bbc
#'
#' @param plot_name ggplot2 object
#' @param pieces plot labels to align
... |
#' Synthetic data for label ranking experiments.
#'
#' @format A matrix of 20 discrete values and 2 columns
#'
"lr.nom"
#' Synthetic data for label ranking experiments.
#'
#' @format A matrix of 20 numeric values and 2 columns
#'
"lr.num"
#' Permutations to be used as rankings
#'
#' @format A matrix of 20 rows ... | /labelrank/R/data.R | no_license | ingted/R-Examples | R | false | false | 341 | r | #' Synthetic data for label ranking experiments.
#'
#' @format A matrix of 20 discrete values and 2 columns
#'
"lr.nom"
#' Synthetic data for label ranking experiments.
#'
#' @format A matrix of 20 numeric values and 2 columns
#'
"lr.num"
#' Permutations to be used as rankings
#'
#' @format A matrix of 20 rows ... |
# setup -------------------------------------------------------------------
vcr::vcr_configure(
dir = cassette_dir("html-entity-encoding")
)
setup({
if (has_pat()) {
ugly_name <<- "> data & < files"
vcr::use_cassette("create-p1", {
p1 <<- osf_create_project(title = "osfr-test-html-entities")
... | /tests/testthat/test-html-entity-encoding.R | permissive | ropensci/osfr | R | false | false | 1,252 | r |
# setup -------------------------------------------------------------------
vcr::vcr_configure(
dir = cassette_dir("html-entity-encoding")
)
setup({
if (has_pat()) {
ugly_name <<- "> data & < files"
vcr::use_cassette("create-p1", {
p1 <<- osf_create_project(title = "osfr-test-html-entities")
... |
library(shiny)
shinyUI(fluidPage(
includeScript("enter.js"),
titlePanel("Shiny Bot"),
sidebarPanel(
wellPanel(
fluidRow(
textInput("texto",label = "Ingrese texto"),
actionButton("enviar", label = "Enviar")
)
),
fluidRow(
wellPanel(
textOutput("respuesta")
... | /ui.R | no_license | AndreAlz/Chatbot-Shiny | R | false | false | 405 | r | library(shiny)
shinyUI(fluidPage(
includeScript("enter.js"),
titlePanel("Shiny Bot"),
sidebarPanel(
wellPanel(
fluidRow(
textInput("texto",label = "Ingrese texto"),
actionButton("enviar", label = "Enviar")
)
),
fluidRow(
wellPanel(
textOutput("respuesta")
... |
#############################################################################
# KS Master AW - R
# jose.ramon.cajide@gmail.com, 2016-01-09
#
# DATAVIZ
#############################################################################
install.packages('ggplot2')
library(ggplot2)
# intro slides ----------------------------... | /Introduccion_a_R/104-ggplot2.R | no_license | joseramoncajide/KSMasterAW | R | false | false | 8,500 | r | #############################################################################
# KS Master AW - R
# jose.ramon.cajide@gmail.com, 2016-01-09
#
# DATAVIZ
#############################################################################
install.packages('ggplot2')
library(ggplot2)
# intro slides ----------------------------... |
#' Creates an RGB preview of a Sentinel product before downloading
#'
#' \code{getSentinel_preview} previews single products as RGB plot which had been queried using \link{getSentinel_query}. The function is useful to apply visual checks to products before downloading them.
#'
#' @inheritParams getSentinel_query
#' @pa... | /R/getSentinel_preview.R | no_license | kostask84/getSpatialData | R | false | false | 5,002 | r | #' Creates an RGB preview of a Sentinel product before downloading
#'
#' \code{getSentinel_preview} previews single products as RGB plot which had been queried using \link{getSentinel_query}. The function is useful to apply visual checks to products before downloading them.
#'
#' @inheritParams getSentinel_query
#' @pa... |
library(shiny)
ui <- fluidPage(
titlePanel("Old Faithful Geyser Data"),
sidebarLayout(
sidebarPanel(
),
mainPanel(
)
)
)
server <- function(input, output) {
}
# Run the application
shinyApp(ui = ui, server = server)
set.seed(123)
x = runif(500)... | /gamviz/app.R | no_license | benearnthof/geostatsBA | R | false | false | 3,009 | r | library(shiny)
ui <- fluidPage(
titlePanel("Old Faithful Geyser Data"),
sidebarLayout(
sidebarPanel(
),
mainPanel(
)
)
)
server <- function(input, output) {
}
# Run the application
shinyApp(ui = ui, server = server)
set.seed(123)
x = runif(500)... |
detsi<-function(pysty,lehtilkm){
#Hakee pysty-vektorista "pysty" sen indeksin, jonka kohdalla
#esiintyy luku "lehtilkm"
#
lkm<-length(pysty)
i<-1
while ((pysty[i]!=lehtilkm) && (i<=lkm)) i<-i+1
return(i)
}
| /delt/R/detsi.R | no_license | ingted/R-Examples | R | false | false | 206 | r | detsi<-function(pysty,lehtilkm){
#Hakee pysty-vektorista "pysty" sen indeksin, jonka kohdalla
#esiintyy luku "lehtilkm"
#
lkm<-length(pysty)
i<-1
while ((pysty[i]!=lehtilkm) && (i<=lkm)) i<-i+1
return(i)
}
|
# Civic Hackathon DC
# Issue Number 17
# Author:Shashank Rai
setwd("/Users/shashankrai/GitHub/dc_restaurant_inspections")
getwd()
#Import Data
#Summary
df_sum <- read.csv("output/potential_inspection_summary_data.csv", strip.white = T, na = c("",NA,"#N/A"))
#Violations
df_viol <-read.csv("output/potential_violation_... | /Data Cleaning.R | no_license | ssr48/Food-and-Safety-Restaurant-Infection | R | false | false | 14,675 | r | # Civic Hackathon DC
# Issue Number 17
# Author:Shashank Rai
setwd("/Users/shashankrai/GitHub/dc_restaurant_inspections")
getwd()
#Import Data
#Summary
df_sum <- read.csv("output/potential_inspection_summary_data.csv", strip.white = T, na = c("",NA,"#N/A"))
#Violations
df_viol <-read.csv("output/potential_violation_... |
# MASSパッケージの読み込み(ないならインストールする)
if(!require(MASS)) install.packages("MASS")
library(MASS)
# igraphパッケージの読み込み(ないならインストールする)
if(!require(igraph)) install.packages("igraph")
library(igraph)
# fdrtoolパッケージの読み込み(ないならインストールする)
if(!require(fdrtool)) install.packages("fdrtool")
library(fdrtool)
###############################... | /src/correlation_utils.R | no_license | kztakemoto/network-analysis-in-biology | R | false | false | 4,253 | r |
# MASSパッケージの読み込み(ないならインストールする)
if(!require(MASS)) install.packages("MASS")
library(MASS)
# igraphパッケージの読み込み(ないならインストールする)
if(!require(igraph)) install.packages("igraph")
library(igraph)
# fdrtoolパッケージの読み込み(ないならインストールする)
if(!require(fdrtool)) install.packages("fdrtool")
library(fdrtool)
###############################... |
testlist <- list(m = NULL, repetitions = 0L, in_m = structure(c(2.31584307392677e+77, 9.53818252170339e+295, 1.22810536108095e+146, 4.12396251261199e-221, 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), .Dim = c(5L, 7L)))
result <- do.call(CNull:::communities_individual_... | /CNull/inst/testfiles/communities_individual_based_sampling_alpha/AFL_communities_individual_based_sampling_alpha/communities_individual_based_sampling_alpha_valgrind_files/1615776753-test.R | no_license | akhikolla/updatedatatype-list2 | R | false | false | 362 | r | testlist <- list(m = NULL, repetitions = 0L, in_m = structure(c(2.31584307392677e+77, 9.53818252170339e+295, 1.22810536108095e+146, 4.12396251261199e-221, 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), .Dim = c(5L, 7L)))
result <- do.call(CNull:::communities_individual_... |
library("ggplot2")
library("fmsb")
Pond_Data <- read.csv("CSV_DataStorage.csv", stringsAsFactors = FALSE)
Pond_Data$Date <- as.Date( Pond_Data$Date )
## Thesue two equations are for area and volume of each measurement for the pond.
Pond_Data$Area <- (((Pond_Data$South + Pond_Data$North + 1500) / 2) * ((Pond_Data$West ... | /RadarPlot.R | no_license | cherrypi/Science-Fair_2019 | R | false | false | 1,659 | r | library("ggplot2")
library("fmsb")
Pond_Data <- read.csv("CSV_DataStorage.csv", stringsAsFactors = FALSE)
Pond_Data$Date <- as.Date( Pond_Data$Date )
## Thesue two equations are for area and volume of each measurement for the pond.
Pond_Data$Area <- (((Pond_Data$South + Pond_Data$North + 1500) / 2) * ((Pond_Data$West ... |
library(tm) #Text Mining Package
library(readr)
Laura_Hillenbrand_Unbroken <- read_csv("~/Masters Projet/Amazon-book reviews/Laura-Hillenbrand-Unbroken.csv",
col_names = FALSE)
## Amazon Review Dataset File 6
length(Laura_Hillenbrand_Unbroken)
head(Laura_Hillenbrand_Unbroken)
ta... | /Coding/FuzzyAmazon6.R | no_license | ApurvaW/COMPARING-HIERARCHICAL-AND-FUZZYC-METHOD-FOR-HIGH-DIMENSIONAL-DATA | R | false | false | 2,511 | r | library(tm) #Text Mining Package
library(readr)
Laura_Hillenbrand_Unbroken <- read_csv("~/Masters Projet/Amazon-book reviews/Laura-Hillenbrand-Unbroken.csv",
col_names = FALSE)
## Amazon Review Dataset File 6
length(Laura_Hillenbrand_Unbroken)
head(Laura_Hillenbrand_Unbroken)
ta... |
#' update_fish
#'
#' @param fish
#'
#' @return an updated fish list
#' @export
#'
#' @examples update_fish(fish %>% mutate(linf = 222))
update_fish <- function(fish){
fish_vars <- formals(create_fish) %>% names() #look up arguments to create fish
update_fish_vars <- fish[fish_vars] %>% names() #find the component... | /R/update_fish.R | permissive | j-verstaen/spasm | R | false | false | 562 | r | #' update_fish
#'
#' @param fish
#'
#' @return an updated fish list
#' @export
#'
#' @examples update_fish(fish %>% mutate(linf = 222))
update_fish <- function(fish){
fish_vars <- formals(create_fish) %>% names() #look up arguments to create fish
update_fish_vars <- fish[fish_vars] %>% names() #find the component... |
#' Check git status
#'
#' Check if there are unstaged or uncommited files and warn the user
check_status <- function() {
status <- git2r::status()
if (length(status$staged) > 0 || length(status$unstaged) > 0) {
usethis::ui_warn(glue::glue(
"There are uncommited files. ",
"You s... | /app/git.R | permissive | sbwilson91/scRNA-tools | R | false | false | 502 | r | #' Check git status
#'
#' Check if there are unstaged or uncommited files and warn the user
check_status <- function() {
status <- git2r::status()
if (length(status$staged) > 0 || length(status$unstaged) > 0) {
usethis::ui_warn(glue::glue(
"There are uncommited files. ",
"You s... |
#rename traits to fancy names for figures
fancy_trait_name_dictionary <- function(dat){
dat <- dat %>%
mutate(trait_fancy = recode(trait_trans,
C_percent = "C %",
CN_ratio = "CN",
dC13_permil = "dC13 ‰",
... | /R/functions/fancy_traits.R | no_license | audhalbritter/trait-driver-analysis | R | false | false | 816 | r | #rename traits to fancy names for figures
fancy_trait_name_dictionary <- function(dat){
dat <- dat %>%
mutate(trait_fancy = recode(trait_trans,
C_percent = "C %",
CN_ratio = "CN",
dC13_permil = "dC13 ‰",
... |
% Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/03_get_histogram.R
\name{get_histogram}
\alias{get_histogram}
\title{get_histogram()}
\usage{
get_histogram(df)
}
\arguments{
\item{df}{dataframe: a dataframe returned by the clean_df() function}
}
\value{
dataframe
}
\description{
Cr... | /man/get_histogram.Rd | no_license | thelayc/laycEnrollment | R | false | false | 648 | rd | % Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/03_get_histogram.R
\name{get_histogram}
\alias{get_histogram}
\title{get_histogram()}
\usage{
get_histogram(df)
}
\arguments{
\item{df}{dataframe: a dataframe returned by the clean_df() function}
}
\value{
dataframe
}
\description{
Cr... |
# Utils -------------------------------------------------------------------
#' Sanitize excel sheet names
#'
#' Convert a vector to valid excel sheet names by:
#' * trimming names down to 31 characters,
#' * ensuring each element of the vector is unique, and
#' * removing the illegal characters `\ / * [ ] : ?`
... | /R/utils.R | no_license | cran/tatoo | R | false | false | 3,152 | r | # Utils -------------------------------------------------------------------
#' Sanitize excel sheet names
#'
#' Convert a vector to valid excel sheet names by:
#' * trimming names down to 31 characters,
#' * ensuring each element of the vector is unique, and
#' * removing the illegal characters `\ / * [ ] : ?`
... |
# The Monty-Hall-Problem:
# There are three different doors and behind of them is the price. Behind the other doors is nothing.
# The gameshow participant selects on of the doors.
# Then the gameshow host opens of the doors behind which there is nothing. Which leaves two doors unopened.
# The gameshow host then as... | /montyhall.R | no_license | JohMueller/SimulateMontyHall | R | false | false | 1,655 | r | # The Monty-Hall-Problem:
# There are three different doors and behind of them is the price. Behind the other doors is nothing.
# The gameshow participant selects on of the doors.
# Then the gameshow host opens of the doors behind which there is nothing. Which leaves two doors unopened.
# The gameshow host then as... |
### Objetos em R
# Vetor: possui 1 dimensao e 1 tipo de dado
vetor1 <- c(1:10)
vetor1
length(vetor1)
mode(vetor1)
class(vetor1)
typeof(vetor1)
# Matriz: possui 2 dimensoes e 1 tipo de dado
matriz1 <- matrix(1:10, nrow =2)
matriz1
length(matriz1)
mode(matriz1)
class(matriz1)
typeof(matriz1)
# Array: possui 2 ou m... | /05-Objetos.R | no_license | rRogick/R_Fundamentos_Parte1 | R | false | false | 1,028 | r | ### Objetos em R
# Vetor: possui 1 dimensao e 1 tipo de dado
vetor1 <- c(1:10)
vetor1
length(vetor1)
mode(vetor1)
class(vetor1)
typeof(vetor1)
# Matriz: possui 2 dimensoes e 1 tipo de dado
matriz1 <- matrix(1:10, nrow =2)
matriz1
length(matriz1)
mode(matriz1)
class(matriz1)
typeof(matriz1)
# Array: possui 2 ou m... |
zpooled_TX <-
function(data, Ns, delta) {
N <- sum(Ns)
if (!is.null(data)) {
x <- data[1,1]
y <- data[1,2]
} else {
x <- rep(0:Ns[1], each=(Ns[2]+1))
y <- rep.int(0:Ns[2], Ns[1]+1)
}
p1 <- x/Ns[1]
p2 <- y/Ns[2]
numerator <- p1 - p2 - delta
if (delta==0) {
denomi... | /R/zpooled_TX.R | no_license | cran/Exact | R | false | false | 1,776 | r | zpooled_TX <-
function(data, Ns, delta) {
N <- sum(Ns)
if (!is.null(data)) {
x <- data[1,1]
y <- data[1,2]
} else {
x <- rep(0:Ns[1], each=(Ns[2]+1))
y <- rep.int(0:Ns[2], Ns[1]+1)
}
p1 <- x/Ns[1]
p2 <- y/Ns[2]
numerator <- p1 - p2 - delta
if (delta==0) {
denomi... |
# BAGGING
# Basic Idea:
# 1. Resample cases & recalculate predictions
# 2. Average or majority vote
# Notes:
# - Similar bias
# - Reduced variance
# - More useful for non linear functions
# -----------------------------------------------------------------------
# The Package is obsolete
# ----------... | /resources/analytics/data_science_specialization/practical_machine_learning/w3-v2-bagging.r | no_license | aceri/portfolio | R | false | false | 1,246 | r | # BAGGING
# Basic Idea:
# 1. Resample cases & recalculate predictions
# 2. Average or majority vote
# Notes:
# - Similar bias
# - Reduced variance
# - More useful for non linear functions
# -----------------------------------------------------------------------
# The Package is obsolete
# ----------... |
# nocov start - compat-purrr (last updated: rlang 0.3.0.9000)
# This file serves as a reference for compatibility functions for
# purrr. They are not drop-in replacements but allow a similar style
# of programming. This is useful in cases where purrr is too heavy a
# package to depend on. Please find the most recent v... | /R/compat-purrr.R | no_license | DavisVaughan/strapgod | R | false | false | 647 | r | # nocov start - compat-purrr (last updated: rlang 0.3.0.9000)
# This file serves as a reference for compatibility functions for
# purrr. They are not drop-in replacements but allow a similar style
# of programming. This is useful in cases where purrr is too heavy a
# package to depend on. Please find the most recent v... |
# goals probability distribution - complete script
source('./loaders/load_matches_from_csv.R')
# libraries
library(ggplot2)
library(reshape)
# real distribution
matches = load.matches.from.csv()
matches = matches[which(matches$season == "2015/2016"),]
goals = c(matches$home_team_goal,matches$away_team_goal)
d = da... | /models/goals_scored/goals_distribution.R | no_license | martin-galajda/ML-soccer-data-project | R | false | false | 1,069 | r | # goals probability distribution - complete script
source('./loaders/load_matches_from_csv.R')
# libraries
library(ggplot2)
library(reshape)
# real distribution
matches = load.matches.from.csv()
matches = matches[which(matches$season == "2015/2016"),]
goals = c(matches$home_team_goal,matches$away_team_goal)
d = da... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/univariate_2avgsev.R
\name{univariate_average_severity}
\alias{univariate_average_severity}
\title{Univariate average claim severity}
\usage{
univariate_average_severity(
df,
x,
severity,
nclaims,
exposure = NULL,
premium = NULL
)... | /man/univariate_average_severity.Rd | no_license | emailhy/insurancerating | R | false | true | 1,453 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/univariate_2avgsev.R
\name{univariate_average_severity}
\alias{univariate_average_severity}
\title{Univariate average claim severity}
\usage{
univariate_average_severity(
df,
x,
severity,
nclaims,
exposure = NULL,
premium = NULL
)... |
snake_case <- purrr::compose(tolower, function(x) gsub("(?<=(\\w))([A-Z])", "_\\2", x, perl = TRUE))
| /snake_case.r | no_license | injuryepi/Utils | R | false | false | 101 | r | snake_case <- purrr::compose(tolower, function(x) gsub("(?<=(\\w))([A-Z])", "_\\2", x, perl = TRUE))
|
UpdateSigma.FL <-
function(survObj, priorPara, ini){
p <- survObj$p
be.ini <- ini$beta.ini
covInv <- ini$covInv
sh.sig <- p/2
rate.sig <- 1/2*as.vector(t(be.ini)%*%covInv%*%be.ini, mode = "numeric")
sigmaSq <- rigamma(1, a = sh.sig, b = rate.sig)
return(sigmaSq)
}
| /R/UpdateSigma.FL.R | no_license | cran/psbcGroup | R | false | false | 293 | r | UpdateSigma.FL <-
function(survObj, priorPara, ini){
p <- survObj$p
be.ini <- ini$beta.ini
covInv <- ini$covInv
sh.sig <- p/2
rate.sig <- 1/2*as.vector(t(be.ini)%*%covInv%*%be.ini, mode = "numeric")
sigmaSq <- rigamma(1, a = sh.sig, b = rate.sig)
return(sigmaSq)
}
|
#### Generate Rmd files for each chapter ------
rm(list = ls())
## Load the form
mainDir <- getwd()
## Load all required packages
source(paste0(mainDir,"/code/0-config.R"))
source(paste0(mainDir,"/code/0-packages.R"))
library(koboloadeR)
### Load the data
cat("\n\n Loading data. It is assumed that the cleaning, weig... | /code/4-generate-report.R | no_license | unhcr-jordan/vaf2017 | R | false | false | 66,512 | r | #### Generate Rmd files for each chapter ------
rm(list = ls())
## Load the form
mainDir <- getwd()
## Load all required packages
source(paste0(mainDir,"/code/0-config.R"))
source(paste0(mainDir,"/code/0-packages.R"))
library(koboloadeR)
### Load the data
cat("\n\n Loading data. It is assumed that the cleaning, weig... |
#####################################################################################################################################################
#' @title FUNCTION_TITLE
#' @description FUNCTION_DESCRIPTION
#' @param location_set_version_id PARAM_DESCRIPTION
#' @param year_start PARAM_DESCRIPTION
#' @param year_en... | /antibiotic_usage/mbg_central/LBDCore/R/get_populations.R | no_license | The-Oxford-GBD-group/antibiotic_modelling_code | R | false | false | 2,203 | r | #####################################################################################################################################################
#' @title FUNCTION_TITLE
#' @description FUNCTION_DESCRIPTION
#' @param location_set_version_id PARAM_DESCRIPTION
#' @param year_start PARAM_DESCRIPTION
#' @param year_en... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/explore.R
\name{encrypt}
\alias{encrypt}
\title{encrypt text}
\usage{
encrypt(text, codeletters = c(toupper(letters), letters, 0:9),
shift = 18)
}
\arguments{
\item{text}{A text (character)}
\item{codeletters}{A string of lette... | /man/encrypt.Rd | no_license | romainfrancois/explore | R | false | true | 500 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/explore.R
\name{encrypt}
\alias{encrypt}
\title{encrypt text}
\usage{
encrypt(text, codeletters = c(toupper(letters), letters, 0:9),
shift = 18)
}
\arguments{
\item{text}{A text (character)}
\item{codeletters}{A string of lette... |
ds <- state.x77
ds[2, 3] <- NA
ds[3, 1] <- NA
ds[2, 4] <- NA
ds[4, 3] <- NA
# (1)
for (i in 1:ncol(ds)) {
cat(colnames(ds)[i], " ", "\t", sum(is.na(ds[, i])), "\n")
}
# (2)
ds[complete.cases(ds),]
# (3)
sum(rowSums(is.na(ds)) > 0)
# (4)
ds.new <- ds[complete.cases(ds),]
| /bigdata_ai_study/chapter_7/1.R | no_license | himitery/dankook | R | false | false | 280 | r | ds <- state.x77
ds[2, 3] <- NA
ds[3, 1] <- NA
ds[2, 4] <- NA
ds[4, 3] <- NA
# (1)
for (i in 1:ncol(ds)) {
cat(colnames(ds)[i], " ", "\t", sum(is.na(ds[, i])), "\n")
}
# (2)
ds[complete.cases(ds),]
# (3)
sum(rowSums(is.na(ds)) > 0)
# (4)
ds.new <- ds[complete.cases(ds),]
|
#5_4_Invertibility
library(tswge)
#MA(2): X_t = a_t -1.6a_t-1 +.9*a_t-2
factor.wge(phi = c(1.6,-.9))
#Invertibily - outside the unit circle
#MA(2): X_t = a_t -1.6a_t-1 -.9*a_t-2
factor.wge(phi = c(1.6,.9))
#Not Invertibil = inside the unit circle
#MA(2): X_t = a_t +1a_t-1 -.3*a_t-2
factor.wge(phi = c(-.1,.3))
#Inver... | /Unit05/5_4_Invertibility.R | no_license | cmadding/MSDS6373 | R | false | false | 740 | r | #5_4_Invertibility
library(tswge)
#MA(2): X_t = a_t -1.6a_t-1 +.9*a_t-2
factor.wge(phi = c(1.6,-.9))
#Invertibily - outside the unit circle
#MA(2): X_t = a_t -1.6a_t-1 -.9*a_t-2
factor.wge(phi = c(1.6,.9))
#Not Invertibil = inside the unit circle
#MA(2): X_t = a_t +1a_t-1 -.3*a_t-2
factor.wge(phi = c(-.1,.3))
#Inver... |
library(mutSignatures)
### Name: getTestRunArgs
### Title: Generate Arguments for Running Examples and Mock Runs
### Aliases: getTestRunArgs
### ** Examples
getTestRunArgs(1)
| /data/genthat_extracted_code/mutSignatures/examples/getTestRunArgs.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 182 | r | library(mutSignatures)
### Name: getTestRunArgs
### Title: Generate Arguments for Running Examples and Mock Runs
### Aliases: getTestRunArgs
### ** Examples
getTestRunArgs(1)
|
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/xgb.plot.shap.R
\name{xgb.plot.shap}
\alias{xgb.plot.shap}
\title{SHAP contribution dependency plots}
\usage{
xgb.plot.shap(data, shap_contrib = NULL, features = NULL, top_n = 1,
model = NULL, trees = NULL, target_class = NULL,
approxcont... | /R-package/man/xgb.plot.shap.Rd | permissive | GAOSHENG5337/xgboost | R | false | true | 6,322 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/xgb.plot.shap.R
\name{xgb.plot.shap}
\alias{xgb.plot.shap}
\title{SHAP contribution dependency plots}
\usage{
xgb.plot.shap(data, shap_contrib = NULL, features = NULL, top_n = 1,
model = NULL, trees = NULL, target_class = NULL,
approxcont... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/IO.R
\docType{class}
\name{IO}
\alias{IO}
\title{IO}
\format{An object of class \code{R6ClassGenerator} of length 24.}
\usage{
myText <- IO$new(name = "skiReport", x = avalanche)
}
\arguments{
\item{path}{Character string containing the file ... | /man/IO.Rd | no_license | john-james-ai/NLPStudio-2.0 | R | false | true | 1,223 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/IO.R
\docType{class}
\name{IO}
\alias{IO}
\title{IO}
\format{An object of class \code{R6ClassGenerator} of length 24.}
\usage{
myText <- IO$new(name = "skiReport", x = avalanche)
}
\arguments{
\item{path}{Character string containing the file ... |
# Already inside server
#PACKAGES
library(shiny)
library(jsonlite)
library(rjson)
library(tidyverse)
library(ggvis)
library(chorddiag)
library(plotly)
library(scales)
library(igraph)
library(ggthemes)
library(shiny)
library(plotly)
options(scipen = 999)
options(scipen = 999)
#**********************************RENDER ... | /movies-main.R | no_license | nashmans/R-ShinyApp-Hollywood-Boxoffice-analysis | R | false | false | 9,488 | r | # Already inside server
#PACKAGES
library(shiny)
library(jsonlite)
library(rjson)
library(tidyverse)
library(ggvis)
library(chorddiag)
library(plotly)
library(scales)
library(igraph)
library(ggthemes)
library(shiny)
library(plotly)
options(scipen = 999)
options(scipen = 999)
#**********************************RENDER ... |
testlist <- list(mu = 3.28850093871934e-320, var = 0)
result <- do.call(metafolio:::est_beta_params,testlist)
str(result) | /metafolio/inst/testfiles/est_beta_params/libFuzzer_est_beta_params/est_beta_params_valgrind_files/1612987689-test.R | no_license | akhikolla/updatedatatype-list3 | R | false | false | 121 | r | testlist <- list(mu = 3.28850093871934e-320, var = 0)
result <- do.call(metafolio:::est_beta_params,testlist)
str(result) |
ctrl1 <- list(adapt_delta = 0.95, stepsize = 0.05)
ctrl2 <- list(adapt_delta = 0.99, stepsize = 0.01, max_treedepth = 11)
ctrl3 <- list(adapt_delta = 0.999, stepsize = 0.001, max_treedepth = 12)
stan_diagnostics <- function(fit) {
ll <- extract_log_lik(fit)
stan_summary <- as.data.frame(summary(fit)$summary)
... | /R/functions.R | no_license | patrickbarks/moving-beta | R | false | false | 3,195 | r |
ctrl1 <- list(adapt_delta = 0.95, stepsize = 0.05)
ctrl2 <- list(adapt_delta = 0.99, stepsize = 0.01, max_treedepth = 11)
ctrl3 <- list(adapt_delta = 0.999, stepsize = 0.001, max_treedepth = 12)
stan_diagnostics <- function(fit) {
ll <- extract_log_lik(fit)
stan_summary <- as.data.frame(summary(fit)$summary)
... |
#' Return epimutations as per Aref-Eshghi et al, 2020.
#'
#' @param cases (GenomicRatioSet, ExpressionSet) Case dataset.
#' @param controls (GenomicRatioSet, ExpressionSet) Control dataset. Optional.
#' @param sample_ids (character vector) The column names in cases to compute
#' epimutations for.
#' If missing, comput... | /R/EpiMutations.R | permissive | bopohdr/epimutacions | R | false | false | 11,407 | r | #' Return epimutations as per Aref-Eshghi et al, 2020.
#'
#' @param cases (GenomicRatioSet, ExpressionSet) Case dataset.
#' @param controls (GenomicRatioSet, ExpressionSet) Control dataset. Optional.
#' @param sample_ids (character vector) The column names in cases to compute
#' epimutations for.
#' If missing, comput... |
#Modelo A
a=rweibull(3400,2.5,200)
#Modelo B
b=rweibull(3400,0.7,200)
#Modelo C
c=rweibull(3400,6,15)
#Modelo D
d=rweibull(3400,1.2,150)
par(mfrow=c(2,2))
hist(a)
hist(b)
hist(c)
hist(d)
par(mfrow=c(1,1))
#Un grafico Cuantil-Cuantil permite observar cuan cerca esta la
#distribucion de un conjunto de datos a alguna dis... | /P1D.R | no_license | ClaudiaHazard/CS_Work3 | R | false | false | 1,527 | r | #Modelo A
a=rweibull(3400,2.5,200)
#Modelo B
b=rweibull(3400,0.7,200)
#Modelo C
c=rweibull(3400,6,15)
#Modelo D
d=rweibull(3400,1.2,150)
par(mfrow=c(2,2))
hist(a)
hist(b)
hist(c)
hist(d)
par(mfrow=c(1,1))
#Un grafico Cuantil-Cuantil permite observar cuan cerca esta la
#distribucion de un conjunto de datos a alguna dis... |
#plot 4
# filter SCC with combution and coal related data
combustion <- grepl(pattern = "combust",x = SCC$SCC.Level.One,ignore.case = TRUE)
coal <- grepl(pattern = "coal",x = SCC$SCC.Level.Four,ignore.case = TRUE)
combustioncoal <- (combustion & coal)
combustionSCC <- SCC[combustioncoal,]$SCC
combustionNEI <- NEI... | /Plot4.R | no_license | freddiefreeloader75/Exploratory-Analysis-2 | R | false | false | 859 | r | #plot 4
# filter SCC with combution and coal related data
combustion <- grepl(pattern = "combust",x = SCC$SCC.Level.One,ignore.case = TRUE)
coal <- grepl(pattern = "coal",x = SCC$SCC.Level.Four,ignore.case = TRUE)
combustioncoal <- (combustion & coal)
combustionSCC <- SCC[combustioncoal,]$SCC
combustionNEI <- NEI... |
\name{standard.ellipse}
\alias{standard.ellipse}
\title{ Standard Ellipse }
\description{
Fits a standard ellipse to bivariate data analytically using maximum
likelihood estimators.
}
\usage{
standard.ellipse(x,y,confs=NULL,steps=5)
}
\arguments{
\item{x}{ Vector of x data.}
\item{y}{ Vector of y data.}
\ite... | /siar/man/standard.ellipse.rd | no_license | albrizre/spatstat.revdep | R | false | false | 1,942 | rd | \name{standard.ellipse}
\alias{standard.ellipse}
\title{ Standard Ellipse }
\description{
Fits a standard ellipse to bivariate data analytically using maximum
likelihood estimators.
}
\usage{
standard.ellipse(x,y,confs=NULL,steps=5)
}
\arguments{
\item{x}{ Vector of x data.}
\item{y}{ Vector of y data.}
\ite... |
### Run r4ss and notes for making model comparison plots and editing plots
### Originally developed for the 2015 China Rockfish assessment document,
### which had three independent assessment models (South of 40-10,
### 40-10 through OR, and WA). Written for up to 3 assessment models
### Even if you only have 1 asses... | /Rcode/0-Run_r4ss_plots.R | no_license | iantaylor-NOAA/YTRK_doc | R | false | false | 22,328 | r | ### Run r4ss and notes for making model comparison plots and editing plots
### Originally developed for the 2015 China Rockfish assessment document,
### which had three independent assessment models (South of 40-10,
### 40-10 through OR, and WA). Written for up to 3 assessment models
### Even if you only have 1 asses... |
### Plot Bison MSMC output - Jared Decker - Julien Soubrier - Ben Rohrlach
# 3 Dec 2014 - modified June 2015
#require(plyr)
library(ggplot2)
# set working directory
#setwd("~/Documents/Semester_Years/2015/Semester2/MSMC/")
### FILE ACQUIRED FROM: alex@Mint17-HP-Studio-XPS-1645 ~/Dropbox/MAGenomics_2015/PSMC Scholars... | /MSMC/alexTests/ms/plot_test-4-1-10m.R | no_license | alex-jackson1994/errorAnalysis | R | false | false | 9,625 | r | ### Plot Bison MSMC output - Jared Decker - Julien Soubrier - Ben Rohrlach
# 3 Dec 2014 - modified June 2015
#require(plyr)
library(ggplot2)
# set working directory
#setwd("~/Documents/Semester_Years/2015/Semester2/MSMC/")
### FILE ACQUIRED FROM: alex@Mint17-HP-Studio-XPS-1645 ~/Dropbox/MAGenomics_2015/PSMC Scholars... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/shiny.R
\name{gt_output}
\alias{gt_output}
\title{Create a \strong{gt} display table output element for Shiny}
\usage{
gt_output(outputId)
}
\arguments{
\item{outputId}{An output variable from which to read the table.}
}
\value{
An object of ... | /man/gt_output.Rd | no_license | cran/gt | R | false | true | 2,602 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/shiny.R
\name{gt_output}
\alias{gt_output}
\title{Create a \strong{gt} display table output element for Shiny}
\usage{
gt_output(outputId)
}
\arguments{
\item{outputId}{An output variable from which to read the table.}
}
\value{
An object of ... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/cache.R
\name{BiocPkgTools-cache}
\alias{BiocPkgTools-cache}
\alias{setCache}
\alias{pkgToolsCache}
\title{Manage cache for BiocPkgTools}
\usage{
setCache(
directory = rappdirs::user_cache_dir("BiocPkgTools"),
verbose = TRUE,
ask = inte... | /man/BiocPkgTools-cache.Rd | permissive | shbrief/BiocPkgTools | R | false | true | 1,530 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/cache.R
\name{BiocPkgTools-cache}
\alias{BiocPkgTools-cache}
\alias{setCache}
\alias{pkgToolsCache}
\title{Manage cache for BiocPkgTools}
\usage{
setCache(
directory = rappdirs::user_cache_dir("BiocPkgTools"),
verbose = TRUE,
ask = inte... |
#Needs input files from twisst_to_bed.R
library(iNEXT)
library(ggplot2)
incfeq_list<-list(as.incfreq(total[4:length(total[1,])]),as.incfreq(total_bf[,4:length(total_bf[1,])]),as.incfreq(total_gf[,4:length(total_gf[1,])]),as.incfreq(total_sf[,4:length(total_sf[1,])]))
#all together (something not working)
out_all<-iNEX... | /R_scripts/Gutturosus_Rarefaction.R | no_license | yuzhenpeng/Genomic-Consequences-of-Speciation-Reversal | R | false | false | 3,900 | r | #Needs input files from twisst_to_bed.R
library(iNEXT)
library(ggplot2)
incfeq_list<-list(as.incfreq(total[4:length(total[1,])]),as.incfreq(total_bf[,4:length(total_bf[1,])]),as.incfreq(total_gf[,4:length(total_gf[1,])]),as.incfreq(total_sf[,4:length(total_sf[1,])]))
#all together (something not working)
out_all<-iNEX... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.