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 |
|---|---|---|---|---|---|---|---|---|---|
% Generated by roxygen2 (4.0.2): do not edit by hand
\name{mem.info}
\alias{mem.info}
\title{Information on objects in R environment}
\usage{
mem.info(envir = .GlobalEnv, sortBy = "Size")
}
\arguments{
\item{envir}{the environment to inspect, default is .GlobalEnv}
\item{sortBy}{the result will be decreasing... | /man/mem.info.Rd | no_license | doomhammerhell/test-datamart | R | false | false | 840 | rd | % Generated by roxygen2 (4.0.2): do not edit by hand
\name{mem.info}
\alias{mem.info}
\title{Information on objects in R environment}
\usage{
mem.info(envir = .GlobalEnv, sortBy = "Size")
}
\arguments{
\item{envir}{the environment to inspect, default is .GlobalEnv}
\item{sortBy}{the result will be decreasing... |
library(glmnet)
mydata = read.table("./TrainingSet/ReliefF/liver.csv",head=T,sep=",")
x = as.matrix(mydata[,4:ncol(mydata)])
y = as.matrix(mydata[,1])
set.seed(123)
glm = cv.glmnet(x,y,nfolds=10,type.measure="mse",alpha=0.65,family="gaussian",standardize=FALSE)
sink('./Model/EN/ReliefF/liver/liver_070.txt',append=TRUE)... | /Model/EN/ReliefF/liver/liver_070.R | no_license | leon1003/QSMART | R | false | false | 350 | r | library(glmnet)
mydata = read.table("./TrainingSet/ReliefF/liver.csv",head=T,sep=",")
x = as.matrix(mydata[,4:ncol(mydata)])
y = as.matrix(mydata[,1])
set.seed(123)
glm = cv.glmnet(x,y,nfolds=10,type.measure="mse",alpha=0.65,family="gaussian",standardize=FALSE)
sink('./Model/EN/ReliefF/liver/liver_070.txt',append=TRUE)... |
# first load matrix consisting of the lrr signals saved when generating the synthetic data
# for example: load('lrr_signals.Rdata')
# source the updated normalization and postnormalization functions
source('norm_star.R')
source('postseg_star.R')
# add probe locations to the lrr signals matrix
data <- data.frame(Pro... | /Methods/Synthetic_data/CGHcallstar_pipeline.R | no_license | adspit/PASCAL | R | false | false | 1,510 | r |
# first load matrix consisting of the lrr signals saved when generating the synthetic data
# for example: load('lrr_signals.Rdata')
# source the updated normalization and postnormalization functions
source('norm_star.R')
source('postseg_star.R')
# add probe locations to the lrr signals matrix
data <- data.frame(Pro... |
% Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/fill.outside.border.R
\name{fill.outside.border}
\alias{fill.outside.border}
\title{Fills space outside the border of a plot.}
\usage{
fill.outside.border(col = 0, rat = 1)
}
\arguments{
\item{col}{The color of the fill, default is 0 ... | /man/fill.outside.border.Rd | no_license | cran/geo | R | false | false | 1,264 | rd | % Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/fill.outside.border.R
\name{fill.outside.border}
\alias{fill.outside.border}
\title{Fills space outside the border of a plot.}
\usage{
fill.outside.border(col = 0, rat = 1)
}
\arguments{
\item{col}{The color of the fill, default is 0 ... |
#Rafael Veloso
#Programming Assignment 1: Air Pollution - Part 2
#https://class.coursera.org/rprog-003/assignment/view?assignment_id=3
# Write a function that reads a directory full of files and reports the number
# of completely observed cases in each data file.
# The function should return a data frame where the ... | /coursera/RProgramming/wk1/complete.R | permissive | rafaelveloso/ds101 | R | false | false | 1,315 | r | #Rafael Veloso
#Programming Assignment 1: Air Pollution - Part 2
#https://class.coursera.org/rprog-003/assignment/view?assignment_id=3
# Write a function that reads a directory full of files and reports the number
# of completely observed cases in each data file.
# The function should return a data frame where the ... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Met_MatH.R
\name{[}
\alias{[}
\alias{[,MatH,ANY,ANY,ANY-method}
\alias{[,MatH-method}
\title{extract from a MatH Method [}
\usage{
\S4method{[}{MatH}(x, i, j, ..., drop = TRUE)
}
\arguments{
\item{x}{a \code{matH} object}
\item{... | /man/extract-methods.Rd | no_license | cran/HistDAWass | R | false | true | 759 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Met_MatH.R
\name{[}
\alias{[}
\alias{[,MatH,ANY,ANY,ANY-method}
\alias{[,MatH-method}
\title{extract from a MatH Method [}
\usage{
\S4method{[}{MatH}(x, i, j, ..., drop = TRUE)
}
\arguments{
\item{x}{a \code{matH} object}
\item{... |
args <- commandArgs(trailingOnly = TRUE)
library(data.table)
library(stringr)
setwd(".")
get_exons<-function(pile_path) {
#Loading the resulting table of samtools mpileup -A --output-QNAME
pile<-fread(pile_path)
#Removing unneccesary columns to save on RAM
pile$V3<-NULL
pile$V4<-NULL
pile$V6<-... | /exons.R | no_license | kbodulic/eunapius_lncRNA | R | false | false | 7,084 | r | args <- commandArgs(trailingOnly = TRUE)
library(data.table)
library(stringr)
setwd(".")
get_exons<-function(pile_path) {
#Loading the resulting table of samtools mpileup -A --output-QNAME
pile<-fread(pile_path)
#Removing unneccesary columns to save on RAM
pile$V3<-NULL
pile$V4<-NULL
pile$V6<-... |
#Title: "ps2 - Data II"
#Author: "Fernando Garcia"
#Date: "2/5/2021"
library(tidyverse)
library(shiny)
library(dplyr)
library(ggplot2)
library(lubridate)
library(sf)
library(viridis)
library(htmlwidgets)
library(htmltools)
library(tigris)
library(reshape2)
rm(list = ls())
setwd("C:/Users/Nano/Dropbox/My PC (DellXPS... | /question_2.R | no_license | nanojgarcia/data_skills_2_r_hw2 | R | false | false | 2,694 | r | #Title: "ps2 - Data II"
#Author: "Fernando Garcia"
#Date: "2/5/2021"
library(tidyverse)
library(shiny)
library(dplyr)
library(ggplot2)
library(lubridate)
library(sf)
library(viridis)
library(htmlwidgets)
library(htmltools)
library(tigris)
library(reshape2)
rm(list = ls())
setwd("C:/Users/Nano/Dropbox/My PC (DellXPS... |
# Optimizing Resistance Surface using ResistanceGA
# Need packages: ResistanceGA , rgdal, otuSummary
# Setting up the workspace
library(ResistanceGA)
library(otuSummary)
library(raster)
library(tidyverse)
library(GA)
library(MuMIn)
library(lme4)
library(gdistance)
library(ggplot2)
library(ggExtra)
library(Matrix)
libr... | /bin/pipeline_3_MS-get-batches.R | no_license | tkchafin/ResistanceGA_HPC_Pipeline | R | false | false | 2,187 | r |
# Optimizing Resistance Surface using ResistanceGA
# Need packages: ResistanceGA , rgdal, otuSummary
# Setting up the workspace
library(ResistanceGA)
library(otuSummary)
library(raster)
library(tidyverse)
library(GA)
library(MuMIn)
library(lme4)
library(gdistance)
library(ggplot2)
library(ggExtra)
library(Matrix)
libr... |
# Exercise 1: calling built-in functions
# Create a variable `my_name` that contains your name
my_name <- "Yilin Chen"
# Create a variable `name_length` that holds how many letters (including spaces)
# are in your name (use the `nchar()` function)
name_length <- nchar(my_name)
# Print the number of letters in your n... | /chapter-06-exercises/exercise-1/exercise.R | permissive | ychen023/book-exercises | R | false | false | 1,539 | r | # Exercise 1: calling built-in functions
# Create a variable `my_name` that contains your name
my_name <- "Yilin Chen"
# Create a variable `name_length` that holds how many letters (including spaces)
# are in your name (use the `nchar()` function)
name_length <- nchar(my_name)
# Print the number of letters in your n... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/farmR_utils.R
\name{decay_i}
\alias{decay_i}
\title{Calculate decay weights.}
\usage{
decay_i(n, l)
}
\arguments{
\item{n}{Numeric value for the number of steps before or after the reference point.}
\item{l}{Numeric value for the decay rate.... | /man/decay_i.Rd | no_license | chrisschuerz/SWATfarmR | R | false | true | 384 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/farmR_utils.R
\name{decay_i}
\alias{decay_i}
\title{Calculate decay weights.}
\usage{
decay_i(n, l)
}
\arguments{
\item{n}{Numeric value for the number of steps before or after the reference point.}
\item{l}{Numeric value for the decay rate.... |
##########################################################################################################################################
##################################################################### Loading Behavioral Measure Files
STAI = read.csv("E:/R Studio/LEMON/STAI_G_X2.csv")
STAXI = read.csv("E:/R... | /morphsim.R | no_license | humaffectneurolab/MorphSim_TraitAnxiety | R | false | false | 22,576 | r | ##########################################################################################################################################
##################################################################### Loading Behavioral Measure Files
STAI = read.csv("E:/R Studio/LEMON/STAI_G_X2.csv")
STAXI = read.csv("E:/R... |
# Run VAMF with 10 percent subset data
## Load VAMF and useful
library(vamf)
library(useful)
## Read in subset matrix. Because duplicate row names exist, set row.names = NULL first (R will create the row names column using numbers)
S <- read.table("10percentCellSubset_allgenes.txt", header=TRUE, quote = "\"'", row.name... | /02_scripts/RunVAMF10percentSubset.r | permissive | singlecell-batches/vamf | R | false | false | 6,710 | r | # Run VAMF with 10 percent subset data
## Load VAMF and useful
library(vamf)
library(useful)
## Read in subset matrix. Because duplicate row names exist, set row.names = NULL first (R will create the row names column using numbers)
S <- read.table("10percentCellSubset_allgenes.txt", header=TRUE, quote = "\"'", row.name... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/autoscaling_operations.R
\name{autoscaling_delete_lifecycle_hook}
\alias{autoscaling_delete_lifecycle_hook}
\title{Deletes the specified lifecycle hook}
\usage{
autoscaling_delete_lifecycle_hook(LifecycleHookName,
AutoScalingGroupName)
}
\a... | /cran/paws.management/man/autoscaling_delete_lifecycle_hook.Rd | permissive | johnnytommy/paws | R | false | true | 1,061 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/autoscaling_operations.R
\name{autoscaling_delete_lifecycle_hook}
\alias{autoscaling_delete_lifecycle_hook}
\title{Deletes the specified lifecycle hook}
\usage{
autoscaling_delete_lifecycle_hook(LifecycleHookName,
AutoScalingGroupName)
}
\a... |
#' @param x any. Object or vector of objects to test.
#' @param all logical. If `FALSE` tests each `x` separately. Otherwise returns `TRUE` only if all `x` pass test.
#' @param bound logical.
| /man-roxygen/param_contains.R | permissive | xoopR/set6 | R | false | false | 193 | r | #' @param x any. Object or vector of objects to test.
#' @param all logical. If `FALSE` tests each `x` separately. Otherwise returns `TRUE` only if all `x` pass test.
#' @param bound logical.
|
library(dplyr)
library(lubridate)
library(wesanderson)
url = 'https://caterpillarscount.unc.edu/iuFYr1xREQOp2ioB5MHvnCTY39UHv2/'
today = strsplit(as.character(Sys.time()), " ")[[1]][1]
plant = read.csv(paste(url, today, "_Plant.csv", sep = ""), header = T, quote = '\"')
survey = read.csv(paste(url, today, "_Survey.c... | /analysis_scripts/fun_summary_2018.r | no_license | hurlbertlab/caterpillars-count-analysis | R | false | false | 3,181 | r | library(dplyr)
library(lubridate)
library(wesanderson)
url = 'https://caterpillarscount.unc.edu/iuFYr1xREQOp2ioB5MHvnCTY39UHv2/'
today = strsplit(as.character(Sys.time()), " ")[[1]][1]
plant = read.csv(paste(url, today, "_Plant.csv", sep = ""), header = T, quote = '\"')
survey = read.csv(paste(url, today, "_Survey.c... |
\name{connectivity}
\title{Connectivity Index - Internal Measure}
\description{
Function evaluates \emph{connectivity} index.
}
\usage{
connectivity(data,clust,neighbour.num, dist="euclidean")
connectivity.diss.mx(diss.mx,clust,neighbour.num)
}
\alias{connectivity}
\alias{connectivity.diss.mx}
\arguments{
\item{data... | /man/connectivity.Rd | no_license | cran/clv | R | false | false | 2,648 | rd | \name{connectivity}
\title{Connectivity Index - Internal Measure}
\description{
Function evaluates \emph{connectivity} index.
}
\usage{
connectivity(data,clust,neighbour.num, dist="euclidean")
connectivity.diss.mx(diss.mx,clust,neighbour.num)
}
\alias{connectivity}
\alias{connectivity.diss.mx}
\arguments{
\item{data... |
#Reading data
fileData <- read.table("household_power_consumption.txt", header = TRUE, sep = ";", stringsAsFactors=FALSE, dec=".")
#subsetting data for dates 2007-02-01 and 2007-02-02
dataSubset <- fileData[fileData$Date %in% c("1/2/2007","2/2/2007") ,]
#x-axis data
dateTime <- strptime(paste(dataSubset$Date, dataSub... | /plot4.R | no_license | mayautobot/ExData_Plotting1 | R | false | false | 1,413 | r | #Reading data
fileData <- read.table("household_power_consumption.txt", header = TRUE, sep = ";", stringsAsFactors=FALSE, dec=".")
#subsetting data for dates 2007-02-01 and 2007-02-02
dataSubset <- fileData[fileData$Date %in% c("1/2/2007","2/2/2007") ,]
#x-axis data
dateTime <- strptime(paste(dataSubset$Date, dataSub... |
# Install and load packages
package_names <- c("survey","dplyr","foreign","devtools")
lapply(package_names, function(x) if(!x %in% installed.packages()) install.packages(x))
lapply(package_names, require, character.only=T)
install_github("e-mitchell/meps_r_pkg/MEPS")
library(MEPS)
options(survey.lonely.ps... | /mepstrends/hc_use/json/code/r/meanEXP__employed__sop__.r | permissive | RandomCriticalAnalysis/MEPS-summary-tables | R | false | false | 2,163 | r | # Install and load packages
package_names <- c("survey","dplyr","foreign","devtools")
lapply(package_names, function(x) if(!x %in% installed.packages()) install.packages(x))
lapply(package_names, require, character.only=T)
install_github("e-mitchell/meps_r_pkg/MEPS")
library(MEPS)
options(survey.lonely.ps... |
#'This functions use to plot earthquakes on relavent map.
#'
#'@param map_dat dataframe that use to draw the map
#'@param annot_col columns used to annotate
#'
#'@value This function will generate interactive map with dots shows the earthquake locations.
#'@examples
#'\dontrun{
#'labeled_map_dat <- map_dat %>% mutate(p... | /R/eq_map.R | no_license | esppk/noaatk | R | false | false | 1,200 | r | #'This functions use to plot earthquakes on relavent map.
#'
#'@param map_dat dataframe that use to draw the map
#'@param annot_col columns used to annotate
#'
#'@value This function will generate interactive map with dots shows the earthquake locations.
#'@examples
#'\dontrun{
#'labeled_map_dat <- map_dat %>% mutate(p... |
#' @name descriptors
#' @aliases descriptors .obs .cols .preds .facts .lvls .x .y .dat
#' @title Data Set Characteristics Available when Fitting Models
#' @description When using the `fit()` functions there are some
#' variables that will be available for use in arguments. For
#' example, if the user would like to ch... | /R/descriptors.R | permissive | jcpsantiago/parsnip | R | false | false | 11,116 | r | #' @name descriptors
#' @aliases descriptors .obs .cols .preds .facts .lvls .x .y .dat
#' @title Data Set Characteristics Available when Fitting Models
#' @description When using the `fit()` functions there are some
#' variables that will be available for use in arguments. For
#' example, if the user would like to ch... |
\name{BridgeRPvalueEvaluation}
\alias{BridgeRPvalueEvaluation}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{
Calculate RNA half-life from BRIC-seq data
}
\description{
Calculate RNA half-life from BRIC-seq data
}
\usage{
BridgeRPvalueEvaluation(InputFile="BridgeR_5C_HalfLife_calculati... | /man/BridgeRPvalueEvaluation.Rd | permissive | AkimitsuLab/BridgeR | R | false | false | 2,521 | rd | \name{BridgeRPvalueEvaluation}
\alias{BridgeRPvalueEvaluation}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{
Calculate RNA half-life from BRIC-seq data
}
\description{
Calculate RNA half-life from BRIC-seq data
}
\usage{
BridgeRPvalueEvaluation(InputFile="BridgeR_5C_HalfLife_calculati... |
# Learn about API authentication here: {{BASE_URL}}/r/getting-started
# Find your api_key here: {{BASE_URL}}/settings/api
library(plotly)
py <- plotly(username='TestBot', key='r1neazxo9w')
trace1 <- list(
x = c(0, 1, 2),
y = c(10, 11, 12),
type = "scatter"
)
trace2 <- list(
x = c(2, 3, 4),
y = c(100, 110... | /auto-docs/executables/r/stacked_coupled_subplots.r | no_license | VukDukic/documentation | R | false | false | 817 | r | # Learn about API authentication here: {{BASE_URL}}/r/getting-started
# Find your api_key here: {{BASE_URL}}/settings/api
library(plotly)
py <- plotly(username='TestBot', key='r1neazxo9w')
trace1 <- list(
x = c(0, 1, 2),
y = c(10, 11, 12),
type = "scatter"
)
trace2 <- list(
x = c(2, 3, 4),
y = c(100, 110... |
library(DESeq2)
library(Biocomb)
source('decomp.R')
source('main/final.R')
load('environment/dds_nor_tum_comb.RData')
load('environment/first_trial_shrunken_classifier.RData')
vs_normal_comb_reported <- t(assay(vst(dds_nor_tum_comb)))
genes.most.varying <- colnames(vs_normal_comb_reported)[get.imp.genes(3,
... | /papillary/main/filter.R | no_license | xulijunji/Stage-Prediction-of-Cancer | R | false | false | 1,185 | r | library(DESeq2)
library(Biocomb)
source('decomp.R')
source('main/final.R')
load('environment/dds_nor_tum_comb.RData')
load('environment/first_trial_shrunken_classifier.RData')
vs_normal_comb_reported <- t(assay(vst(dds_nor_tum_comb)))
genes.most.varying <- colnames(vs_normal_comb_reported)[get.imp.genes(3,
... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/generated_client.R
\name{workflows_post_git_commits}
\alias{workflows_post_git_commits}
\title{Commit and push a new version of the file}
\usage{
workflows_post_git_commits(id, content, message, file_hash)
}
\arguments{
\item{id}{integer requ... | /man/workflows_post_git_commits.Rd | no_license | JosiahParry/civis-r | R | false | true | 862 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/generated_client.R
\name{workflows_post_git_commits}
\alias{workflows_post_git_commits}
\title{Commit and push a new version of the file}
\usage{
workflows_post_git_commits(id, content, message, file_hash)
}
\arguments{
\item{id}{integer requ... |
library(shiny)
library(plotly)
pollutants <- 1:16
names(pollutants) <- c('Barium', 'Beryllium', 'Cadmium', 'Calcium', 'Chromium', 'Copper',
'Iron', 'Lead', 'Manganese', 'Molybdenum', 'Nickel', 'Vanadium', 'Zinc',
'Sulfur dioxide', 'Carbon monoxide', 'Ozone')
shinyUI(fluid... | /DevelopingDataProduct/Week4_ProgrammingAssignment/GasMetalPollution/ui.R | no_license | imreyes/datasciencecoursera | R | false | false | 3,448 | r | library(shiny)
library(plotly)
pollutants <- 1:16
names(pollutants) <- c('Barium', 'Beryllium', 'Cadmium', 'Calcium', 'Chromium', 'Copper',
'Iron', 'Lead', 'Manganese', 'Molybdenum', 'Nickel', 'Vanadium', 'Zinc',
'Sulfur dioxide', 'Carbon monoxide', 'Ozone')
shinyUI(fluid... |
# Push with the following: git push origin master
#update.packages(checkBuilt=TRUE, ask=FALSE)
#install.packages(c("devtools", "dplyr", "mice", "googledrive"))
#devtools::install_github(c("tidyverse/googlesheets4"))
library(mice)
library(googledrive)
library(googlesheets4)
#==========================================... | /WWASP.R | no_license | donavenom/WWASP | R | false | false | 91,111 | r | # Push with the following: git push origin master
#update.packages(checkBuilt=TRUE, ask=FALSE)
#install.packages(c("devtools", "dplyr", "mice", "googledrive"))
#devtools::install_github(c("tidyverse/googlesheets4"))
library(mice)
library(googledrive)
library(googlesheets4)
#==========================================... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/myseq_n.R
\name{myseq_n}
\alias{myseq_n}
\title{Get the value from the formula}
\usage{
myseq_n(x, n)
}
\arguments{
\item{x}{numeric}
\item{n}{integer which is >0}
}
\value{
the answer of the recursive sequence
}
\description{
For hw04 funct... | /man/myseq_n.Rd | permissive | Stephanie9606/R_Package_MathFormula | R | false | true | 569 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/myseq_n.R
\name{myseq_n}
\alias{myseq_n}
\title{Get the value from the formula}
\usage{
myseq_n(x, n)
}
\arguments{
\item{x}{numeric}
\item{n}{integer which is >0}
}
\value{
the answer of the recursive sequence
}
\description{
For hw04 funct... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/medianeffect.R
\name{print.drug_effects}
\alias{print.drug_effects}
\title{Print method for objects of drug_effects class}
\usage{
\method{print}{drug_effects}(x, ..., stats = TRUE)
}
\arguments{
\item{x}{A drug_effects object}
\item{...}{(n... | /man/print.drug_effects.Rd | no_license | jhchou/medianeffect | R | false | true | 470 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/medianeffect.R
\name{print.drug_effects}
\alias{print.drug_effects}
\title{Print method for objects of drug_effects class}
\usage{
\method{print}{drug_effects}(x, ..., stats = TRUE)
}
\arguments{
\item{x}{A drug_effects object}
\item{...}{(n... |
#################################################
## Antarctica Tourism & Recreation Goal
## STEP 2: Overlaying the data and obtaining global reference points
#################################################
library(sp)
library(rgdal)
library(RColorBrewer)
library(colorspace)
rm(list = ls())
setwd("/var/data/ohi/mo... | /Antarctica/AQ-Livelihood_v2014/dataPrep/OverlayCoordinateData.R | no_license | yan-cri/ohiprep | R | false | false | 1,806 | r | #################################################
## Antarctica Tourism & Recreation Goal
## STEP 2: Overlaying the data and obtaining global reference points
#################################################
library(sp)
library(rgdal)
library(RColorBrewer)
library(colorspace)
rm(list = ls())
setwd("/var/data/ohi/mo... |
# Matrix inversion is usually a costly computation and there may be some benefit
# to caching the inverse of a matrix rather than compute it repeatedly. The
# following two functions are used to cache the inverse of a matrix.
# makeCacheMatrix creates a list containing a function to
# 1. set the value of the matrix
# ... | /CacheMatrix.R | no_license | ThotaSravani/ProgrammingAssignment2 | R | false | false | 1,660 | r | # Matrix inversion is usually a costly computation and there may be some benefit
# to caching the inverse of a matrix rather than compute it repeatedly. The
# following two functions are used to cache the inverse of a matrix.
# makeCacheMatrix creates a list containing a function to
# 1. set the value of the matrix
# ... |
#Trees and Random Forests
#simple dataset where the outcome grows 0.75 units on average
#for every increase in a predictor
library(dplyr)
library(ggplot2)
library(rpart)
n <- 1000
sigma <- 0.25
set.seed(1)
x <- rnorm(n, 0, 1)
y <- 0.75 * x + rnorm(n, 0, sigma)
dat <- data.frame(x = x, y = y)
#fit the r... | /machine_learning/classification/Trees_and_Random_Forests.R | no_license | Pongsasit/HavardX_data_sciece | R | false | false | 1,123 | r | #Trees and Random Forests
#simple dataset where the outcome grows 0.75 units on average
#for every increase in a predictor
library(dplyr)
library(ggplot2)
library(rpart)
n <- 1000
sigma <- 0.25
set.seed(1)
x <- rnorm(n, 0, 1)
y <- 0.75 * x + rnorm(n, 0, sigma)
dat <- data.frame(x = x, y = y)
#fit the r... |
# plot1.R - Code required for a simple histogram
# Create directory for data files, download file from UCI, unzip and load it into data frame
if (!file.exists("data")) {
dir.create("data")
}
url = "https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip"
download.file(url, destfil... | /plot1.R | no_license | mjc-mia/ExData_Plotting1 | R | false | false | 1,158 | r | # plot1.R - Code required for a simple histogram
# Create directory for data files, download file from UCI, unzip and load it into data frame
if (!file.exists("data")) {
dir.create("data")
}
url = "https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip"
download.file(url, destfil... |
library(copBasic)
### Name: wolfCOP
### Title: The Schweizer and Wolff Sigma of a Copula
### Aliases: wolfCOP
### Keywords: copula (characteristics) copula (properties)
### ** Examples
## Not run:
##D wolfCOP(cop=PSP) # 0.4784176
## End(Not run)
## Not run:
##D n <- 1000; UV <- simCOP(n=n, cop=N4212cop, para=7.5... | /data/genthat_extracted_code/copBasic/examples/wolfCOP.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 2,307 | r | library(copBasic)
### Name: wolfCOP
### Title: The Schweizer and Wolff Sigma of a Copula
### Aliases: wolfCOP
### Keywords: copula (characteristics) copula (properties)
### ** Examples
## Not run:
##D wolfCOP(cop=PSP) # 0.4784176
## End(Not run)
## Not run:
##D n <- 1000; UV <- simCOP(n=n, cop=N4212cop, para=7.5... |
library(distr)
### Name: options
### Title: additional options in package 'distr'
### Aliases: options newDevice
### Keywords: environment iplot dplot
### ** Examples
getOption("newDevice")
options("newDevice"=TRUE)
| /data/genthat_extracted_code/distr/examples/options.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 225 | r | library(distr)
### Name: options
### Title: additional options in package 'distr'
### Aliases: options newDevice
### Keywords: environment iplot dplot
### ** Examples
getOption("newDevice")
options("newDevice"=TRUE)
|
# Define simulation parameters
sim_params <- list(timestep = 0.05,
endTime = 100)
# Model Parameters (List)
model_params <- list(vols = c(vol = 5e-14),
init_conc = c(Prot_inact = 5,
Prot_act = 0))
# Input calcium time series
input_df <- re... | /material/test_ode_glycphos.R | no_license | jpahle/CalciumModelsLibrary | R | false | false | 1,067 | r | # Define simulation parameters
sim_params <- list(timestep = 0.05,
endTime = 100)
# Model Parameters (List)
model_params <- list(vols = c(vol = 5e-14),
init_conc = c(Prot_inact = 5,
Prot_act = 0))
# Input calcium time series
input_df <- re... |
genZ2X <-
function (genZ, reference = "F2", max.level = NULL, max.dom = NULL)
{
ans <- NULL
eff <- effectsNamesGeneral(nloc = ncol(genZ)/3, max.level = max.level,
max.dom = max.dom)
for (e in rev(eff)) {
if (!(e %in% colnames(ans))) {
partial <- partialX(genZ = genZ, reference ... | /R/genZ2X.R | no_license | cran/noia | R | false | false | 679 | r | genZ2X <-
function (genZ, reference = "F2", max.level = NULL, max.dom = NULL)
{
ans <- NULL
eff <- effectsNamesGeneral(nloc = ncol(genZ)/3, max.level = max.level,
max.dom = max.dom)
for (e in rev(eff)) {
if (!(e %in% colnames(ans))) {
partial <- partialX(genZ = genZ, reference ... |
# Clearing Environ ment
rm(list = ls())
#insatll Required packages for the project
x = c("lubridate","dplyr","mice","VIM","Amelia","missForest",
"e1071","ggplot2","corrplot","rpart","geosphere","corrgram",
"DMwR","purrr","geosphere","rlist","PerformanceAnalytics",
"xgboost","car","caret","rand... | /carfare_prediction-edwisorproject-1.R | no_license | Pavanmithare/CabFare-Prediction | R | false | false | 43,530 | r | # Clearing Environ ment
rm(list = ls())
#insatll Required packages for the project
x = c("lubridate","dplyr","mice","VIM","Amelia","missForest",
"e1071","ggplot2","corrplot","rpart","geosphere","corrgram",
"DMwR","purrr","geosphere","rlist","PerformanceAnalytics",
"xgboost","car","caret","rand... |
#!/usr/bin/env Rscript
# pca with rsvd
# cjfiscus
library(pacman)
p_load(data.table, rsvd)
args = commandArgs(trailingOnly=TRUE)
# read in GC corrected, normalized data
print("reading in data")
counts<-fread(args[1])
dim(counts)
counts[1:5,1:5]
## DROP OUTGROUPS
drop<-c("A_lyrata1", "A_lyrata2", "C_rubella1", "C_ru... | /chapter_1/analysis_scripts/kmer_pl/008b_pca.R | permissive | cjfiscus/2022_Fiscus_Dissertation | R | false | false | 1,766 | r | #!/usr/bin/env Rscript
# pca with rsvd
# cjfiscus
library(pacman)
p_load(data.table, rsvd)
args = commandArgs(trailingOnly=TRUE)
# read in GC corrected, normalized data
print("reading in data")
counts<-fread(args[1])
dim(counts)
counts[1:5,1:5]
## DROP OUTGROUPS
drop<-c("A_lyrata1", "A_lyrata2", "C_rubella1", "C_ru... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/draggableModalDialog.R
\name{draggableModalDialog}
\alias{draggableModalDialog}
\title{Create a draggable modal dialog UI}
\usage{
draggableModalDialog(
...,
title = NULL,
footer = shiny::modalButton("Dismiss"),
size = c("m", "s", "l"... | /man/draggableModalDialog.Rd | no_license | danielleoneil/shinyjqui | R | false | true | 1,363 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/draggableModalDialog.R
\name{draggableModalDialog}
\alias{draggableModalDialog}
\title{Create a draggable modal dialog UI}
\usage{
draggableModalDialog(
...,
title = NULL,
footer = shiny::modalButton("Dismiss"),
size = c("m", "s", "l"... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/rustiefel.R
\name{rustiefel}
\alias{rustiefel}
\title{Siumlate a Uniformly Distributed Random Orthonormal Matrix}
\usage{
rustiefel(m, R)
}
\arguments{
\item{m}{the length of each column vector.}
\item{R}{the number of column vectors.}
}
\va... | /man/rustiefel.Rd | no_license | pdhoff/rstiefel | R | false | true | 739 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/rustiefel.R
\name{rustiefel}
\alias{rustiefel}
\title{Siumlate a Uniformly Distributed Random Orthonormal Matrix}
\usage{
rustiefel(m, R)
}
\arguments{
\item{m}{the length of each column vector.}
\item{R}{the number of column vectors.}
}
\va... |
## Reading in datasets
library(dplyr)
NEI <- readRDS("summarySCC_PM25.rds")
SCC <- readRDS("Source_Classification_Code.rds")
NEI <- tbl_df(NEI)
SCC <- tbl_df(SCC)
## Return list of SCC with EI.Sector ending with "Coal"
sVehicle <- SCC %>% mutate(Mobile.Vehicle = (grepl("(^Mobile.+Vehicles)", EI.Sector))) %>% filte... | /plot6.R | no_license | gordchan/ExData_Plotting2 | R | false | false | 1,329 | r | ## Reading in datasets
library(dplyr)
NEI <- readRDS("summarySCC_PM25.rds")
SCC <- readRDS("Source_Classification_Code.rds")
NEI <- tbl_df(NEI)
SCC <- tbl_df(SCC)
## Return list of SCC with EI.Sector ending with "Coal"
sVehicle <- SCC %>% mutate(Mobile.Vehicle = (grepl("(^Mobile.+Vehicles)", EI.Sector))) %>% filte... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/milne-pc-spectrum.R
\name{is.milne_pc_spectrum}
\alias{is.milne_pc_spectrum}
\title{Check for class "milne_pc_spectrum"}
\usage{
is.milne_pc_spectrum(x)
}
\arguments{
\item{x}{Object to check.}
}
\value{
Logical scalar.
}
\description{
Checks... | /man/is.milne_pc_spectrum.Rd | permissive | pmcharrison/hrep | R | false | true | 374 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/milne-pc-spectrum.R
\name{is.milne_pc_spectrum}
\alias{is.milne_pc_spectrum}
\title{Check for class "milne_pc_spectrum"}
\usage{
is.milne_pc_spectrum(x)
}
\arguments{
\item{x}{Object to check.}
}
\value{
Logical scalar.
}
\description{
Checks... |
#' Irvine Robustness Recommendation
#'
#' Provides recommendations for consistency score and configurational n thresholds to attain a desired level of confidence in a QCA algorithm application.
#' @import QCAGUI bootstrap
#' @importFrom graphics hist
#' @importFrom stats glm plogis predict quantile
#' @importFrom util... | /package/iaQCA.Rcheck/00_pkg_src/iaQCA/R/irrQCA.R | no_license | cbengibson/QCArevision2 | R | false | false | 2,404 | r | #' Irvine Robustness Recommendation
#'
#' Provides recommendations for consistency score and configurational n thresholds to attain a desired level of confidence in a QCA algorithm application.
#' @import QCAGUI bootstrap
#' @importFrom graphics hist
#' @importFrom stats glm plogis predict quantile
#' @importFrom util... |
#' Harmonic regression model
#'
#' Computes amplitudes and phase angle in the typical harmonic regression framework.
#' Based on these estimates a harmonic regression function is fitted.
#'
#' @param y numeric vector containing time series on which harmonic
#' regression will be fitt... | /R/harmonicR.R | no_license | inder-tg/geoTS | R | false | false | 3,185 | r | #' Harmonic regression model
#'
#' Computes amplitudes and phase angle in the typical harmonic regression framework.
#' Based on these estimates a harmonic regression function is fitted.
#'
#' @param y numeric vector containing time series on which harmonic
#' regression will be fitt... |
epc <- read.table("household_power_consumption.txt", header = T, sep = ";")
epc$Date <- as.Date(epc$Date, format="%d/%m/%Y")
plot_df <- epc[(epc$Date=="2007-02-01") | (epc$Date=="2007-02-02"),]
plot_df$Global_active_power <- as.numeric(as.character(plot_df$Global_active_power))
plot_df$Global_reactive_power <- as.nume... | /plot3.R | no_license | KylerEqui/ExData_Plotting1 | R | false | false | 1,185 | r | epc <- read.table("household_power_consumption.txt", header = T, sep = ";")
epc$Date <- as.Date(epc$Date, format="%d/%m/%Y")
plot_df <- epc[(epc$Date=="2007-02-01") | (epc$Date=="2007-02-02"),]
plot_df$Global_active_power <- as.numeric(as.character(plot_df$Global_active_power))
plot_df$Global_reactive_power <- as.nume... |
#!/exports/applications/apps/SL7/R/3.3.2/bin/Rscript
library(retimes)
library(rstan)
library(ggplot2)
library(retimes)
library(rstan)
library(doBy)
library(ggplot2)
library(brms)
rstan_options(auto_write = TRUE)
options(mc.cores = parallel::detectCores())
set.seed(123)
ads <- read.csv("exp2_adults.csv")
fives <- read... | /BRMS_Analysis_Expt2.r | no_license | hughrabagliati/BRMS_TurnTaking | R | false | false | 8,002 | r | #!/exports/applications/apps/SL7/R/3.3.2/bin/Rscript
library(retimes)
library(rstan)
library(ggplot2)
library(retimes)
library(rstan)
library(doBy)
library(ggplot2)
library(brms)
rstan_options(auto_write = TRUE)
options(mc.cores = parallel::detectCores())
set.seed(123)
ads <- read.csv("exp2_adults.csv")
fives <- read... |
# INTERNAL
Nonpareil.__init_globals <- function(soft=TRUE){
if(soft && exists('Nonpareil.LastFactor')) return();
Nonpareil.LastFactor <<- NULL;
Nonpareil.LastXmax <<- NULL;
Nonpareil.OpenColors <<- c();
Nonpareil.OpenNames <<- c();
}
# MODEL FUNCTIONS
#Nonpareil.f <- function(x,a,b){ return( ( 1 - exp(-x/(2^a)) ... | /utils/Nonpareil.R | permissive | ikauser7/nonpareil | R | false | false | 7,603 | r |
# INTERNAL
Nonpareil.__init_globals <- function(soft=TRUE){
if(soft && exists('Nonpareil.LastFactor')) return();
Nonpareil.LastFactor <<- NULL;
Nonpareil.LastXmax <<- NULL;
Nonpareil.OpenColors <<- c();
Nonpareil.OpenNames <<- c();
}
# MODEL FUNCTIONS
#Nonpareil.f <- function(x,a,b){ return( ( 1 - exp(-x/(2^a)) ... |
36
1 [19, 27, 7] 8 8 8 18 18
2 [20, 27, 7] 1 2 10 2 20
3 [19, 27, 7] 1 2 12 2 22
4 [20, 27, 7] 1 2 14 2 24
5 [19, 27, 7] 1 2 16 2 26
6 [20, 27, 7] 1 2 18 2 28
7 [19, 27, 7] 1 2 20 2 30
8 [19, 20, 7] 7 1 21 2 32
9 [19, 20, 31] 12 12 33 18 50
10 [19, 20, 32] 1 2 35 2 52
11 [19, 20, 31] 1 2 37 2 54
12 [19, 20, 32] 1 2 39 ... | /advanced algorithm/round3/k-server-analysis-master/data/tests/case159.rd | no_license | tawlas/master_2_school_projects | R | false | false | 2,890 | rd | 36
1 [19, 27, 7] 8 8 8 18 18
2 [20, 27, 7] 1 2 10 2 20
3 [19, 27, 7] 1 2 12 2 22
4 [20, 27, 7] 1 2 14 2 24
5 [19, 27, 7] 1 2 16 2 26
6 [20, 27, 7] 1 2 18 2 28
7 [19, 27, 7] 1 2 20 2 30
8 [19, 20, 7] 7 1 21 2 32
9 [19, 20, 31] 12 12 33 18 50
10 [19, 20, 32] 1 2 35 2 52
11 [19, 20, 31] 1 2 37 2 54
12 [19, 20, 32] 1 2 39 ... |
/Modelacion/Fase5v3.0.R | no_license | esppi/Stochastic-Dynamic-Programming-Application | R | false | false | 12,383 | r | ||
#' Plot PCA component loadings from a recipe or workflow
#'
#' A plot of the component loadings for each original column of the data is
#' produced.
#' @inheritParams get_loading_data
#' @return A `ggplot` object.
#' @examples
#' library(recipes)
#' library(parsnip)
#' library(workflows)
#' library(ggplot2)
#'
#' data(... | /R/plot_loadings.R | permissive | SNAnalyst/learntidymodels | R | false | false | 2,199 | r | #' Plot PCA component loadings from a recipe or workflow
#'
#' A plot of the component loadings for each original column of the data is
#' produced.
#' @inheritParams get_loading_data
#' @return A `ggplot` object.
#' @examples
#' library(recipes)
#' library(parsnip)
#' library(workflows)
#' library(ggplot2)
#'
#' data(... |
modify <- new.env(parent = .GlobalEnv)
# locus -----------------------------------------------------------------------
locus <- copy(sql$output$locus)
setf(locus, j = Cs(init_disp, ovr_disp), stringi::stri_trim)
locus[, init_disp := wccmh::locus_word2num(init_disp)]
locus[, ovr_disp := wccmh::locus_word2num(ovr_disp)]... | /UM/LOCUS/Code/2 modify loc.R | no_license | JamesDalrymple/CMH | R | false | false | 3,604 | r | modify <- new.env(parent = .GlobalEnv)
# locus -----------------------------------------------------------------------
locus <- copy(sql$output$locus)
setf(locus, j = Cs(init_disp, ovr_disp), stringi::stri_trim)
locus[, init_disp := wccmh::locus_word2num(init_disp)]
locus[, ovr_disp := wccmh::locus_word2num(ovr_disp)]... |
#set working directory
path <- getwd()
# Get the data
url <- "https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip"
zip <- "Dataset.zip"
if (!file.exists(path)) {
dir.create(path)
}
download.file(url, file.path(path, zip))
# Load data
f <- "household_power_consumption.txt"
data <- ... | /plot1.R | no_license | aivars-sablis/ExData_Plotting1 | R | false | false | 947 | r | #set working directory
path <- getwd()
# Get the data
url <- "https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip"
zip <- "Dataset.zip"
if (!file.exists(path)) {
dir.create(path)
}
download.file(url, file.path(path, zip))
# Load data
f <- "household_power_consumption.txt"
data <- ... |
testlist <- list(m = NULL, repetitions = 0L, in_m = structure(c(2.31584307392674e+77, 5.14939201014751e+306, 1.22810536108214e+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_beta/AFL_communities_individual_based_sampling_beta/communities_individual_based_sampling_beta_valgrind_files/1615829008-test.R | no_license | akhikolla/updatedatatype-list2 | R | false | false | 361 | r | testlist <- list(m = NULL, repetitions = 0L, in_m = structure(c(2.31584307392674e+77, 5.14939201014751e+306, 1.22810536108214e+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_... |
#qsub -v script=${R script name} Rsubmit_args.sh
# R/3.4.3
setwd("/projects/korstanje-lab/ytakemon/JAC_DO_Kidney/")
load("./RNAseq_data/DO188b_kidney.RData")
library(dplyr)
# parameters
addscan.dir <- "./QTLscan/addscan_prot_perAge/18mo/"
file.name <- function(i) paste0(annot.protein$id[i],"_",annot.protein$symbol[i],... | /QTLmapping/scan_perAge/protein/Gather_scan_p18.R | permissive | ytakemon/JAC_DO_Kidney | R | false | false | 1,189 | r | #qsub -v script=${R script name} Rsubmit_args.sh
# R/3.4.3
setwd("/projects/korstanje-lab/ytakemon/JAC_DO_Kidney/")
load("./RNAseq_data/DO188b_kidney.RData")
library(dplyr)
# parameters
addscan.dir <- "./QTLscan/addscan_prot_perAge/18mo/"
file.name <- function(i) paste0(annot.protein$id[i],"_",annot.protein$symbol[i],... |
example4.initials <- data.frame(
Parameter = c('CL','Q','V1','V2','XYZ','IC1','IC2','CV'),
Type = c('P','P','P','P','L','IC','IC','V'),
Value = c(1.5,2,2,1,1.8,0,0,0.1),
Fixed = c(0,0,0,0,0,1,1,0),
Lower.bound = c(0,0,0,0,0,0,0,0),
Upper.bound = c(100,100,200,200,10,1,1,1)
)
| /data/example4.initials.R | no_license | sbihorel/scaRabee | R | false | false | 276 | r | example4.initials <- data.frame(
Parameter = c('CL','Q','V1','V2','XYZ','IC1','IC2','CV'),
Type = c('P','P','P','P','L','IC','IC','V'),
Value = c(1.5,2,2,1,1.8,0,0,0.1),
Fixed = c(0,0,0,0,0,1,1,0),
Lower.bound = c(0,0,0,0,0,0,0,0),
Upper.bound = c(100,100,200,200,10,1,1,1)
)
|
# HotPho.R
# Kuan Huang @ WashU 2017 March
# extract association data to find hot "subnetworks" of each kinase
# choose kinase/phosphotase, cancer , significance level, model -----------------------------------------------
protein <- "kinase"
sig = 0.05
strict_sig = 0.01
# library ------------------------------------... | /phospho_network/pathway/HotPho.R | no_license | ding-lab/phosphoproteomics | R | false | false | 5,053 | r | # HotPho.R
# Kuan Huang @ WashU 2017 March
# extract association data to find hot "subnetworks" of each kinase
# choose kinase/phosphotase, cancer , significance level, model -----------------------------------------------
protein <- "kinase"
sig = 0.05
strict_sig = 0.01
# library ------------------------------------... |
# modeldb/ProjectService.proto
#
# No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
#
# The version of the OpenAPI document: version not set
#
# Generated by: https://openapi-generator.tech
#' @docType class
#' @title ModeldbLogProjectCodeVersion
#'
#' @descri... | /R/modeldb_log_project_code_version.R | no_license | botchkoAI/VertaProjectService | R | false | false | 3,051 | r | # modeldb/ProjectService.proto
#
# No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
#
# The version of the OpenAPI document: version not set
#
# Generated by: https://openapi-generator.tech
#' @docType class
#' @title ModeldbLogProjectCodeVersion
#'
#' @descri... |
## makeCacheMatrix function intializes x, m and assigns some default values to functions set,
## get, setinverse and get inverse. It also stores inverse matrix value in Cache until the matrix is changed
## cacheSolve returns cashed value of inverse of matrix if it exsists, when a new matrix is passed it recalculates t... | /cachematrix.R | no_license | akandira/ProgrammingAssignment2 | R | false | false | 1,082 | r | ## makeCacheMatrix function intializes x, m and assigns some default values to functions set,
## get, setinverse and get inverse. It also stores inverse matrix value in Cache until the matrix is changed
## cacheSolve returns cashed value of inverse of matrix if it exsists, when a new matrix is passed it recalculates t... |
process_gene_block = function(param, genefm, snpsfm, cvrt_qr, acmefm, workdir){
# library(ACMEeqtl)
# library(filematrix)
fm = fm.open(file.path(workdir, genefm), readonly = TRUE);
genemat = fm[, param$geneset];
close(fm);
fm = fm.open(file.path(workdir, snpsfm), readonly = TRUE);
... | /R/parallel_process.r | no_license | SrishtiJ1305/ACMEeqtl | R | false | false | 7,293 | r | process_gene_block = function(param, genefm, snpsfm, cvrt_qr, acmefm, workdir){
# library(ACMEeqtl)
# library(filematrix)
fm = fm.open(file.path(workdir, genefm), readonly = TRUE);
genemat = fm[, param$geneset];
close(fm);
fm = fm.open(file.path(workdir, snpsfm), readonly = TRUE);
... |
#SQL COMMAND ----------------------------------------------------------
# SELECT r.id,
# age,
# workclasses.name AS workclass,
# education_levels.name AS education_levels,
# r.education_num,
# marital_statuses.name AS martial_status,
# oc... | /Damon_Neanover_RCode.R | no_license | dneanover/data-scientist-exercise01 | R | false | false | 12,111 | r | #SQL COMMAND ----------------------------------------------------------
# SELECT r.id,
# age,
# workclasses.name AS workclass,
# education_levels.name AS education_levels,
# r.education_num,
# marital_statuses.name AS martial_status,
# oc... |
myfunction <- function(x)
{
x <- rnorm(100)
mean(x)
}
| /1st func.R | no_license | arrfreak/R-Programming | R | false | false | 58 | r | myfunction <- function(x)
{
x <- rnorm(100)
mean(x)
}
|
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/data.R
\docType{data}
\name{tgs00026}
\alias{tgs00026}
\title{Auxiliary Data}
\format{
data_frame
}
\usage{
tgs00026
}
\description{
Auxiliary Data Sets
}
\details{
Disposable income of private households by NUTS 2 regions
Retrieved with: \co... | /man/tgs00026.Rd | permissive | dieghernan/eurostat | R | false | true | 551 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/data.R
\docType{data}
\name{tgs00026}
\alias{tgs00026}
\title{Auxiliary Data}
\format{
data_frame
}
\usage{
tgs00026
}
\description{
Auxiliary Data Sets
}
\details{
Disposable income of private households by NUTS 2 regions
Retrieved with: \co... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/security.service.R
\name{getSecurityDataPointNumber}
\alias{getSecurityDataPointNumber}
\title{Returns current numerical value data-point tag for a security}
\usage{
getSecurityDataPointNumber(identifier, tag)
}
\arguments{
\item{identifier}{... | /man/getSecurityDataPointNumber.Rd | no_license | mjdhasan/intrinoR | R | false | true | 1,120 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/security.service.R
\name{getSecurityDataPointNumber}
\alias{getSecurityDataPointNumber}
\title{Returns current numerical value data-point tag for a security}
\usage{
getSecurityDataPointNumber(identifier, tag)
}
\arguments{
\item{identifier}{... |
for (n in 1:25) {
if (n%%2==0) {
cat(n,"is an even\n") # Testing for even or odd
} else {
cat(n," is an odd\n")
}
if (n%%10==0) {
cat(n," is a multiple of 10\n")
}
} | /modulus.R | no_license | dtonthat2/chem160module13 | R | false | false | 209 | r | for (n in 1:25) {
if (n%%2==0) {
cat(n,"is an even\n") # Testing for even or odd
} else {
cat(n," is an odd\n")
}
if (n%%10==0) {
cat(n," is a multiple of 10\n")
}
} |
#' Sequential Monte Carlo Methods for Markov Random Fields
#'
#' This package contains codes for running sequential Monte Carlo (SMC) for
#' simple latent Gaussian Markov random field (GMRF) where the observations are
#' Poisson or binomial. The methodology is introduced in Lindsten, Helske, Vihola (2018).
#'
#' @do... | /R/particlefield-package.R | no_license | helske/particlefield | R | false | false | 466 | r | #' Sequential Monte Carlo Methods for Markov Random Fields
#'
#' This package contains codes for running sequential Monte Carlo (SMC) for
#' simple latent Gaussian Markov random field (GMRF) where the observations are
#' Poisson or binomial. The methodology is introduced in Lindsten, Helske, Vihola (2018).
#'
#' @do... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/lapv.R
\name{bil.lapv}
\alias{bil.lapv}
\title{Vytvori Bilan model s parametry ziskanymi kalibraci pro vybrane LAPV}
\usage{
bil.lapv(ID, type = "m", ...)
}
\arguments{
\item{ID}{ID lokality}
\item{type}{Typ modelu, vetsinou mesicni (tj. vyc... | /man/bil.lapv.Rd | no_license | hanel/hmkzLAPV | R | false | true | 671 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/lapv.R
\name{bil.lapv}
\alias{bil.lapv}
\title{Vytvori Bilan model s parametry ziskanymi kalibraci pro vybrane LAPV}
\usage{
bil.lapv(ID, type = "m", ...)
}
\arguments{
\item{ID}{ID lokality}
\item{type}{Typ modelu, vetsinou mesicni (tj. vyc... |
#############################################################
## set the data directory
#############################################################
data.dir <- '/Users/elizabethsweeney/Dropbox/JHUDASH/'
#############################################################
## load the data
#################################... | /BaltimoreCityBikeLanes/bikelanemap.R | no_license | kbroman/jhudashbike | R | false | false | 2,840 | r | #############################################################
## set the data directory
#############################################################
data.dir <- '/Users/elizabethsweeney/Dropbox/JHUDASH/'
#############################################################
## load the data
#################################... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/CdmAtlasCutover.R
\name{insertCdmSources}
\alias{insertCdmSources}
\title{insertCdmSources}
\usage{
insertCdmSources(repoConnectionDetails, cdmSources, sourceIdx = FALSE,
daimonIdx = FALSE, sqlOnly = FALSE)
}
\arguments{
\item{repoConnectio... | /man/insertCdmSources.Rd | permissive | OHDSI/CdmAtlasCutover | R | false | true | 1,054 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/CdmAtlasCutover.R
\name{insertCdmSources}
\alias{insertCdmSources}
\title{insertCdmSources}
\usage{
insertCdmSources(repoConnectionDetails, cdmSources, sourceIdx = FALSE,
daimonIdx = FALSE, sqlOnly = FALSE)
}
\arguments{
\item{repoConnectio... |
### COMMENTS BY KRISTOFFER HELLTON :
# Analysis of gene expression in Adipose tissue
# Outline
# 1. Select top 1000 genes correlated with outcome for analysis
# 2. Find ridge estimate by LOOCV, inspect the value
# 3. Estimate the (in-sample) sigma^2 by ridge tuned by LOOCV
# 4. Estimate out-of-sample the LOOCV estima... | /SourceAndDataFiles/weight_gain.R | no_license | markvdwiel/Hyperpar | R | false | false | 5,312 | r | ### COMMENTS BY KRISTOFFER HELLTON :
# Analysis of gene expression in Adipose tissue
# Outline
# 1. Select top 1000 genes correlated with outcome for analysis
# 2. Find ridge estimate by LOOCV, inspect the value
# 3. Estimate the (in-sample) sigma^2 by ridge tuned by LOOCV
# 4. Estimate out-of-sample the LOOCV estima... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/rshps.R
\name{rshps}
\alias{rshps}
\title{Get Relaiontship Descriptives of Sociomatrix}
\usage{
rshps(m)
}
\arguments{
\item{m}{A matrix with individuals ordered identically in rows and columns.}
}
\value{
a list of total, unknown... | /man/rshps.Rd | no_license | cran/compete | R | false | true | 462 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/rshps.R
\name{rshps}
\alias{rshps}
\title{Get Relaiontship Descriptives of Sociomatrix}
\usage{
rshps(m)
}
\arguments{
\item{m}{A matrix with individuals ordered identically in rows and columns.}
}
\value{
a list of total, unknown... |
#------------------------------------------------------------------------------#
# Replace Kern #
#------------------------------------------------------------------------------#
#' ReplaceKern
#'
#' \code{ReplaceKern} Replace Kern
#'
#' A wrapper for \co... | /R/ReplaceKern.R | no_license | john-james-ai/NLPStudio-2.0 | R | false | false | 1,786 | r | #------------------------------------------------------------------------------#
# Replace Kern #
#------------------------------------------------------------------------------#
#' ReplaceKern
#'
#' \code{ReplaceKern} Replace Kern
#'
#' A wrapper for \co... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/twsim2.R
\name{det_outcome}
\alias{det_outcome}
\title{Function to determine whether to sample from binary outcome or the real line}
\usage{
det_outcome(var, treat_effect = NULL, x = NULL)
}
\description{
Function to determine whether to samp... | /man/det_outcome.Rd | no_license | ibrahimalnafrah/panelsim | R | false | true | 362 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/twsim2.R
\name{det_outcome}
\alias{det_outcome}
\title{Function to determine whether to sample from binary outcome or the real line}
\usage{
det_outcome(var, treat_effect = NULL, x = NULL)
}
\description{
Function to determine whether to samp... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/avatar.R
\name{wndr_get_avatar}
\alias{wndr_get_avatar}
\title{Avatar API}
\usage{
wndr_get_avatar(user_id, size = c(25, 28, 30, 32, 50, 54, 56, 60, 64, 108,
128, 135, 256, 270, 512), fallback = TRUE)
}
\arguments{
\item{user_id}{User ID.}
... | /man/wndr_get_avatar.Rd | no_license | yutannihilation/wunderlistr | R | false | true | 892 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/avatar.R
\name{wndr_get_avatar}
\alias{wndr_get_avatar}
\title{Avatar API}
\usage{
wndr_get_avatar(user_id, size = c(25, 28, 30, 32, 50, 54, 56, 60, 64, 108,
128, 135, 256, 270, 512), fallback = TRUE)
}
\arguments{
\item{user_id}{User ID.}
... |
testlist <- list(b = c(50401024L, 0L, 0L, 0L))
result <- do.call(mcga:::ByteVectorToDoubles,testlist)
str(result) | /mcga/inst/testfiles/ByteVectorToDoubles/AFL_ByteVectorToDoubles/ByteVectorToDoubles_valgrind_files/1613101780-test.R | no_license | akhikolla/updatedatatype-list3 | R | false | false | 113 | r | testlist <- list(b = c(50401024L, 0L, 0L, 0L))
result <- do.call(mcga:::ByteVectorToDoubles,testlist)
str(result) |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/iam_operations.R
\name{iam_list_user_tags}
\alias{iam_list_user_tags}
\title{Lists the tags that are attached to the specified user}
\usage{
iam_list_user_tags(UserName, Marker, MaxItems)
}
\arguments{
\item{UserName}{[required] The name of t... | /paws/man/iam_list_user_tags.Rd | permissive | sanchezvivi/paws | R | false | true | 2,049 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/iam_operations.R
\name{iam_list_user_tags}
\alias{iam_list_user_tags}
\title{Lists the tags that are attached to the specified user}
\usage{
iam_list_user_tags(UserName, Marker, MaxItems)
}
\arguments{
\item{UserName}{[required] The name of t... |
library("twitteR")
library("ROAuth")
cred <- OAuthFactory$new(consumerKey='N1ULs6gmyRUiGWjCHvO6xOQGo', # Consumer Key (API Key)
consumerSecret='g4vM12p5osTyC7c5gEwM2eXCIqvRBqlLFJX24aR8ddFjBnqU2Q', #Consumer Secret (API Secret)
requestURL='https://api.twitter.com/oauth/r... | /text mining/twi_ext.R | no_license | Vivek-DataScientist/assignments | R | false | false | 3,801 | r | library("twitteR")
library("ROAuth")
cred <- OAuthFactory$new(consumerKey='N1ULs6gmyRUiGWjCHvO6xOQGo', # Consumer Key (API Key)
consumerSecret='g4vM12p5osTyC7c5gEwM2eXCIqvRBqlLFJX24aR8ddFjBnqU2Q', #Consumer Secret (API Secret)
requestURL='https://api.twitter.com/oauth/r... |
library(here)
library(gifski)
library(grid)
library(gganimate)
## command for generating stimulus_frameS
## ffmpeg -i FAM_LL_outcome_1280x960.mp4 -stimulus_frames_pilot1b/FAM_LL_1b_outcome_1280x960_%04d.png
source(here::here("helper/common.R"))
source(here("helper/preprocessing_helper.R"))
source(here("metadata/pod.R... | /pilot_analysis/animation_analysis.R | permissive | GalRaz/mb2-analysis | R | false | false | 12,665 | r | library(here)
library(gifski)
library(grid)
library(gganimate)
## command for generating stimulus_frameS
## ffmpeg -i FAM_LL_outcome_1280x960.mp4 -stimulus_frames_pilot1b/FAM_LL_1b_outcome_1280x960_%04d.png
source(here::here("helper/common.R"))
source(here("helper/preprocessing_helper.R"))
source(here("metadata/pod.R... |
\name{p2minpp}
\alias{p2minpp}
\title{
Conversion of a frequentist p-value to a lower bound of the posterior
probability that the null hypothesis is true assuming equal odds of the
null and the alternative
}
\description{
This function computes the approximate lower bound to the posterior
probability of the null hypoth... | /man/p2minpp.Rd | no_license | cran/evidence | R | false | false | 1,130 | rd | \name{p2minpp}
\alias{p2minpp}
\title{
Conversion of a frequentist p-value to a lower bound of the posterior
probability that the null hypothesis is true assuming equal odds of the
null and the alternative
}
\description{
This function computes the approximate lower bound to the posterior
probability of the null hypoth... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/tailor_methods.R
\name{tailor_predict}
\alias{tailor_predict}
\title{tailor_predict}
\usage{
tailor_predict(
data,
tailor_obj,
n_batch = 64,
parallel = FALSE,
verbose = FALSE
)
}
\arguments{
\item{data}{A flowSet, flowFrame or a mat... | /man/tailor_predict.Rd | no_license | matei-ionita/Tailor | R | false | true | 1,806 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/tailor_methods.R
\name{tailor_predict}
\alias{tailor_predict}
\title{tailor_predict}
\usage{
tailor_predict(
data,
tailor_obj,
n_batch = 64,
parallel = FALSE,
verbose = FALSE
)
}
\arguments{
\item{data}{A flowSet, flowFrame or a mat... |
#' Options for the psyverse package
#'
#' The `psyverse::opts` object contains three functions to set, get, and reset
#' options used by the escalc package. Use `psyverse::opts$set` to set options,
#' `psyverse::opts$get` to get options, or `psyverse::opts$reset` to reset specific or
#' all options to their defaul... | /R/opts.R | no_license | cran/psyverse | R | false | false | 3,657 | r | #' Options for the psyverse package
#'
#' The `psyverse::opts` object contains three functions to set, get, and reset
#' options used by the escalc package. Use `psyverse::opts$set` to set options,
#' `psyverse::opts$get` to get options, or `psyverse::opts$reset` to reset specific or
#' all options to their defaul... |
library(ggplot2)
library(dplyr)
graph=read.csv("GC_content.csv")
graphed=ggplot(aes(x=G,,y=C,color=Species,alpha=I(0.5)),data=graph) + #set axes variables and color/transparency of points
geom_point() + #making it a scatterplot
theme_classic() + #using the classic theme
labs(title="%G versus %C in sequence data o... | /Publicationworthy_scatterplot.R | no_license | nestorgrandal/Rentrez | R | false | false | 704 | r | library(ggplot2)
library(dplyr)
graph=read.csv("GC_content.csv")
graphed=ggplot(aes(x=G,,y=C,color=Species,alpha=I(0.5)),data=graph) + #set axes variables and color/transparency of points
geom_point() + #making it a scatterplot
theme_classic() + #using the classic theme
labs(title="%G versus %C in sequence data o... |
#' Gradient Boosting with Additive Models
#'
#' Gradient boosting for optimizing arbitrary loss functions, where
#' component-wise arbitrary base-learners, e.g., smoothing procedures, are
#' utilized as additive base-learners.
#'
#' @param family optional \code{\link[mboost]{Family}} object. Set
#' automatically acc... | /R/ML_GAMBoostModel.R | no_license | brian-j-smith/MachineShop | R | false | false | 4,290 | r | #' Gradient Boosting with Additive Models
#'
#' Gradient boosting for optimizing arbitrary loss functions, where
#' component-wise arbitrary base-learners, e.g., smoothing procedures, are
#' utilized as additive base-learners.
#'
#' @param family optional \code{\link[mboost]{Family}} object. Set
#' automatically acc... |
context("miss_cat")
mc_result <- miss_cat(airquality,
"Solar.R",
"Ozone")
test_that("the length of miss_cat is what we expect",{
expect_equal(length(mc_result),nrow(airquality))
})
test_that("miss_cat produces character vector",{
expect_is(mc_result,"character")
})
te... | /tests/testthat/test-miss-cat.R | no_license | umeshach/naniar | R | false | false | 563 | r | context("miss_cat")
mc_result <- miss_cat(airquality,
"Solar.R",
"Ozone")
test_that("the length of miss_cat is what we expect",{
expect_equal(length(mc_result),nrow(airquality))
})
test_that("miss_cat produces character vector",{
expect_is(mc_result,"character")
})
te... |
# Load required packages.
library(caret)
library(MASS)
library(randomForest)
# For cross-validation purposes.
fitControl <- trainControl(
method = "repeatedcv",
number = 4,
repeats = 10,
savePred = TRUE)
linearRegressionModel <- function(dataset) {
partition <- makePartition(dataset, 300, 0.8, dataset$month... | /Marcin-Dziadus/scripts/Regression.R | no_license | Maciej-Poleski/labs-untested | R | false | false | 1,493 | r | # Load required packages.
library(caret)
library(MASS)
library(randomForest)
# For cross-validation purposes.
fitControl <- trainControl(
method = "repeatedcv",
number = 4,
repeats = 10,
savePred = TRUE)
linearRegressionModel <- function(dataset) {
partition <- makePartition(dataset, 300, 0.8, dataset$month... |
# Yige Wu @WashU Mar 2021
# set up libraries and output directory -----------------------------------
## set working directory
dir_base = "~/Box/Ding_Lab/Projects_Current/RCC/ccRCC_snRNA/"
setwd(dir_base)
source("./ccRCC_snRNA_analysis/load_pkgs.R")
source("./ccRCC_snRNA_analysis/functions.R")
source("./ccRCC_snRNA_an... | /findmarkers/bap1_vs_pbrm1_nonmutant/summarize_degs/summarize_BAP1_vs_PBRM1_NonMutant_DEGs.R | no_license | ding-lab/ccRCC_snRNA_analysis | R | false | false | 3,460 | r | # Yige Wu @WashU Mar 2021
# set up libraries and output directory -----------------------------------
## set working directory
dir_base = "~/Box/Ding_Lab/Projects_Current/RCC/ccRCC_snRNA/"
setwd(dir_base)
source("./ccRCC_snRNA_analysis/load_pkgs.R")
source("./ccRCC_snRNA_analysis/functions.R")
source("./ccRCC_snRNA_an... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/ChronsTrack2SpatialLineDF.r
\name{ChronsTrack2SpatialLineDF}
\alias{ChronsTrack2SpatialLineDF}
\title{XXX}
\usage{
ChronsTrack2SpatialLineDF(input = chrons, what.ships = c("SCO3", "DAN2"))
}
\description{
XXX
}
| /man/ChronsTrack2SpatialLineDF.Rd | no_license | einarhjorleifsson/datrasr | R | false | true | 289 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/ChronsTrack2SpatialLineDF.r
\name{ChronsTrack2SpatialLineDF}
\alias{ChronsTrack2SpatialLineDF}
\title{XXX}
\usage{
ChronsTrack2SpatialLineDF(input = chrons, what.ships = c("SCO3", "DAN2"))
}
\description{
XXX
}
|
#source("./code/sql/sql_queries_MIMIC2.R")
tablelist <- list(wide_ccu_dx, ccu_vitals, ccu_labs, ccu_patients_id_los, ccu_demographics_dob_gender_death,
ccu_uo_24h, ccu_RRT24h, ccu_vent, wide_procedures_24, wide_pressors, wide_pressors_firsthour,
ccu_gcs, ccu_mortality, ccu_bmi, char... | /analysis/eICU/2. Join Data.R | permissive | criticaldata/953-2019-team_i | R | false | false | 4,670 | r | #source("./code/sql/sql_queries_MIMIC2.R")
tablelist <- list(wide_ccu_dx, ccu_vitals, ccu_labs, ccu_patients_id_los, ccu_demographics_dob_gender_death,
ccu_uo_24h, ccu_RRT24h, ccu_vent, wide_procedures_24, wide_pressors, wide_pressors_firsthour,
ccu_gcs, ccu_mortality, ccu_bmi, char... |
#' Get allele frequencies
#'
#' This function converts loci into data frames consisting of
#' alleles, stratum, frequencies, etc.
#' @param x Either a vector of types \code{locus} or a \code{data.frame}
#' containing \code{locus} objects.
#' @param loci The loci to get frequencies from (default is all).
#' @param st... | /R/frequencies.R | no_license | dyerlab/gstudio | R | false | false | 5,840 | r | #' Get allele frequencies
#'
#' This function converts loci into data frames consisting of
#' alleles, stratum, frequencies, etc.
#' @param x Either a vector of types \code{locus} or a \code{data.frame}
#' containing \code{locus} objects.
#' @param loci The loci to get frequencies from (default is all).
#' @param st... |
/*
* File: fsys.r
* Contents: close, chdir, exit, getenv, open, read, reads, remove, rename,
* [save], seek, stop, system, where, write, writes, [getch, getche, kbhit]
*/
#if MICROSOFT || SCO_XENIX
#define BadCode
#endif /* MICROSOFT || SCO_XENIX */
#ifdef XENIX_386
#define register
#endif /* XENIX_386 ... | /tags/start/unicon/src/runtime/fsys.r | no_license | svn2github/unicon | R | false | false | 55,478 | r | /*
* File: fsys.r
* Contents: close, chdir, exit, getenv, open, read, reads, remove, rename,
* [save], seek, stop, system, where, write, writes, [getch, getche, kbhit]
*/
#if MICROSOFT || SCO_XENIX
#define BadCode
#endif /* MICROSOFT || SCO_XENIX */
#ifdef XENIX_386
#define register
#endif /* XENIX_386 ... |
847bc27d1b5310fc1f41c63f39da971f query34_query34_1344n.qdimacs 1063 2469 | /code/dcnf-ankit-optimized/Results/QBFLIB-2018/E1+A1/Database/Jordan-Kaiser/reduction-finding-full-set-params-k1c3n4/query34_query34_1344n/query34_query34_1344n.R | no_license | arey0pushpa/dcnf-autarky | R | false | false | 72 | r | 847bc27d1b5310fc1f41c63f39da971f query34_query34_1344n.qdimacs 1063 2469 |
\name{xmp15.09}
\alias{xmp15.09}
\docType{data}
\title{data from Example 15.9}
\description{
The \code{xmp15.09} data frame has 7 rows and 5 columns.
}
\format{
This data frame contains the following columns:
\describe{
\item{X4.inch}{
a numeric vector
}
\item{X6.inch}{
a numeric vector
... | /man/xmp15.09.Rd | no_license | dmbates/Devore6 | R | false | false | 644 | rd | \name{xmp15.09}
\alias{xmp15.09}
\docType{data}
\title{data from Example 15.9}
\description{
The \code{xmp15.09} data frame has 7 rows and 5 columns.
}
\format{
This data frame contains the following columns:
\describe{
\item{X4.inch}{
a numeric vector
}
\item{X6.inch}{
a numeric vector
... |
luasLingkaran = function(r){
pi = 3.14
luas = pi*r^2
return(luas)
}
luasPersegi = function(p,l){
luas = p*l
return(luas)
}
luasSegitiga = function(a,t){
return(a*t/2)
}
berhitung = function(z){
for (x in 1:z) {
print(x)
}
} | /function.R | no_license | fajarkurniawan12/R | R | false | false | 246 | r | luasLingkaran = function(r){
pi = 3.14
luas = pi*r^2
return(luas)
}
luasPersegi = function(p,l){
luas = p*l
return(luas)
}
luasSegitiga = function(a,t){
return(a*t/2)
}
berhitung = function(z){
for (x in 1:z) {
print(x)
}
} |
\encoding{UTF-8}
\name{pattPC.fit}
\alias{pattPC.fit}
\title{Function to fit a pattern model for paired comparisons}
\description{%
Function to fit a pattern model for paired comparisons allowing for missing values using a CL approach.
}
\usage{
pattPC.fit(obj, nitems, formel = ~1, elim = ~1, resptype = "pair... | /man/pattPC.fit.Rd | no_license | cran/prefmod | R | false | false | 8,889 | rd | \encoding{UTF-8}
\name{pattPC.fit}
\alias{pattPC.fit}
\title{Function to fit a pattern model for paired comparisons}
\description{%
Function to fit a pattern model for paired comparisons allowing for missing values using a CL approach.
}
\usage{
pattPC.fit(obj, nitems, formel = ~1, elim = ~1, resptype = "pair... |
library(hts)
### Name: htseg1
### Title: Simple examples of hierarchical time series.
### Aliases: htseg1 htseg2
### Keywords: datasets
### ** Examples
plot(htseg1)
| /data/genthat_extracted_code/hts/examples/htseg1.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 174 | r | library(hts)
### Name: htseg1
### Title: Simple examples of hierarchical time series.
### Aliases: htseg1 htseg2
### Keywords: datasets
### ** Examples
plot(htseg1)
|
\name{NEWS}
\title{lfe news}
\section{Changes in version 2.8-5}{
\itemize{
\item Corrected the vignette about estimable functions. The
change in the \code{base::sample()} function made the examples meaningless, and I
forgot to fix it in 2.8-3.
}
}
\section{Changes in version 2.8-4}{
\itemize{
\it... | /inst/NEWS.Rd | no_license | sgaure/lfe | R | false | false | 6,949 | rd | \name{NEWS}
\title{lfe news}
\section{Changes in version 2.8-5}{
\itemize{
\item Corrected the vignette about estimable functions. The
change in the \code{base::sample()} function made the examples meaningless, and I
forgot to fix it in 2.8-3.
}
}
\section{Changes in version 2.8-4}{
\itemize{
\it... |
#' Identify and merge overlapping glyph assignments
#'
#' merge_overlaps checks glyph positions against glyph width and heights to
#' identify groups of overlapping glyphs. It then computes an alternative GLYPH
#' variable that assigns all glyphs in an overlapping group to the same name.
#'
#' @keywords internal
#'... | /R/merge_overlaps.r | no_license | garrettgman/ggplyr | R | false | false | 1,157 | r | #' Identify and merge overlapping glyph assignments
#'
#' merge_overlaps checks glyph positions against glyph width and heights to
#' identify groups of overlapping glyphs. It then computes an alternative GLYPH
#' variable that assigns all glyphs in an overlapping group to the same name.
#'
#' @keywords internal
#'... |
rm(list=ls())
# set working directory to script
wd <- "/projectnb2/sph795/markhz/TwitterScripts"
setwd(wd)
# import packages and functions
library(tidyverse)
library(tictoc)
library(sf)
library(tidycensus)
library(RColorBrewer)
library(ggpubr)
source("twitter_food_functions.R")
# -------------------------------... | /stateAnalysis.R | no_license | markhz/TwitterCovidDietScripts | R | false | false | 5,218 | r |
rm(list=ls())
# set working directory to script
wd <- "/projectnb2/sph795/markhz/TwitterScripts"
setwd(wd)
# import packages and functions
library(tidyverse)
library(tictoc)
library(sf)
library(tidycensus)
library(RColorBrewer)
library(ggpubr)
source("twitter_food_functions.R")
# -------------------------------... |
plot_data <- function (X, y, m, h = NULL, f = NULL) {
##########################################################################
# FUNCTION
# plot_data(X,y,m,h)
# Plotting utility, capable of visualizing 2-dimensional datasets that
# consist of, at most, 7 classes. It plots with different colors: (a) the
# ve... | /Feature/plot_data.R | no_license | daelsepara/pixelprocessing | R | false | false | 2,256 | r | plot_data <- function (X, y, m, h = NULL, f = NULL) {
##########################################################################
# FUNCTION
# plot_data(X,y,m,h)
# Plotting utility, capable of visualizing 2-dimensional datasets that
# consist of, at most, 7 classes. It plots with different colors: (a) the
# ve... |
# Using the jpeg package read in the following picture. Use the parameter
# native=TRUE. What are the 30th and 80th quantiles of the resulting data?
ex2<-function()
{
library(jpeg)
pic<-readJPEG(source = "./Getting and Cleaning Data/Quiz3/ex2.jpg",
native = TRUE)
quantile(pic, probs... | /Getting and Cleaning Data/Quiz3/ex2.R | no_license | OlegRozenshtain/datasciencecoursera | R | false | false | 351 | r | # Using the jpeg package read in the following picture. Use the parameter
# native=TRUE. What are the 30th and 80th quantiles of the resulting data?
ex2<-function()
{
library(jpeg)
pic<-readJPEG(source = "./Getting and Cleaning Data/Quiz3/ex2.jpg",
native = TRUE)
quantile(pic, probs... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.