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
# # Copyright 2007-2018 The OpenMx Project # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable ...
/SilveR/R-3.5.1/library/OpenMx/models/passing/test_thresh_kept_in_order.R
permissive
kevinmiles/SilveR
R
false
false
2,711
r
# # Copyright 2007-2018 The OpenMx Project # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable ...
# linear regression model <- lm(mpg ~ hp + wt, data = mtcars) print(model)
/regression model.R
no_license
frameskywalker/datarockie-data-wrangling
R
false
false
74
r
# linear regression model <- lm(mpg ~ hp + wt, data = mtcars) print(model)
## ---- evo-org-gauss ---- library("R6") source("gaussie.R") source("loggie.R") EvoOrganismGauss <- R6Class( "EvoOrganismGauss", inherit = EvoOrganism, private = list( determineTempParam = function() { tx <- super$get_envTemperature() tmw <- super$get_tempOpt() tsd <- 10 if (tx > 0...
/EvoOrganismGauss.R
no_license
achimrumberger/umwelt_evo
R
false
false
762
r
## ---- evo-org-gauss ---- library("R6") source("gaussie.R") source("loggie.R") EvoOrganismGauss <- R6Class( "EvoOrganismGauss", inherit = EvoOrganism, private = list( determineTempParam = function() { tx <- super$get_envTemperature() tmw <- super$get_tempOpt() tsd <- 10 if (tx > 0...
plot3 <- function(){ fh <- file("household_power_consumption.txt","r"); power <- read.table(text = grep("^[1,2]/2/2007",readLines(fh),value=TRUE) ,header = TRUE, sep = ";" ,na.strings = "?") close(fh) png("plot3.png",width=480,height=480, units ="px") dates <- strpt...
/plot3.R
no_license
marwagamal/ExData_Plotting1
R
false
false
769
r
plot3 <- function(){ fh <- file("household_power_consumption.txt","r"); power <- read.table(text = grep("^[1,2]/2/2007",readLines(fh),value=TRUE) ,header = TRUE, sep = ";" ,na.strings = "?") close(fh) png("plot3.png",width=480,height=480, units ="px") dates <- strpt...
context('Stan Bridge Sampler Bugs') test_that("subscript out of bounds error", { ## https://github.com/quentingronau/bridgesampling/issues/26 stan_mod = " data{ int M; int J; int T; int E; int G; int N[G]; int ii[M]; int jj[M]; int gg[M]; int g_all[sum(N)]; int y[M]; ...
/tests/testthat/test-stan_bridge_sampler_bugs.R
no_license
quentingronau/bridgesampling
R
false
false
5,850
r
context('Stan Bridge Sampler Bugs') test_that("subscript out of bounds error", { ## https://github.com/quentingronau/bridgesampling/issues/26 stan_mod = " data{ int M; int J; int T; int E; int G; int N[G]; int ii[M]; int jj[M]; int gg[M]; int g_all[sum(N)]; int y[M]; ...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/fars_functions.R \name{fars_map_state} \alias{fars_map_state} \title{Map the data points on a map over the selected state This function maps the state given by the user (using the \code{state}) and the datapoints for the year given by the use...
/man/fars_map_state.Rd
no_license
Ademo73/Coursera_assignment
R
false
true
1,697
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/fars_functions.R \name{fars_map_state} \alias{fars_map_state} \title{Map the data points on a map over the selected state This function maps the state given by the user (using the \code{state}) and the datapoints for the year given by the use...
#' Generate frequent items using the apriori algorithm #' #' @description #' This function takes in a factorized Boolean matrix and generate frequent itemsets #' that meet all the user provided criteria provided by the calling function. #' #' @param apriori_input_df An input factorized Boolean dataframe with multiple i...
/R/run_apriori_freqitems.R
permissive
Leehyeji789/RareComb
R
false
false
3,438
r
#' Generate frequent items using the apriori algorithm #' #' @description #' This function takes in a factorized Boolean matrix and generate frequent itemsets #' that meet all the user provided criteria provided by the calling function. #' #' @param apriori_input_df An input factorized Boolean dataframe with multiple i...
# Make jsons from preprocessed csv/excel datasets - numbers from various sources collected by Martha Johnson, Victoria Lee, Sandy Baum library(dplyr) library(stringr) source("scripts/createJsons.R") boxpath <- "/Users/vhou/Box Sync/COMM/**Project Folders**/College Affordability (Lumina) Project/**Production/" ######...
/scripts/processExistingDatasets.R
no_license
UrbanInstitute/ed-data
R
false
false
1,552
r
# Make jsons from preprocessed csv/excel datasets - numbers from various sources collected by Martha Johnson, Victoria Lee, Sandy Baum library(dplyr) library(stringr) source("scripts/createJsons.R") boxpath <- "/Users/vhou/Box Sync/COMM/**Project Folders**/College Affordability (Lumina) Project/**Production/" ######...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/initializer.R \name{mx.init.create} \alias{mx.init.create} \title{Create initialization of argument like arg.array} \usage{ mx.init.create(initializer, shape.array, ctx, skip.unknown = TRUE) } \arguments{ \item{initializer}{The initializer.}...
/R-package/man/mx.init.create.Rd
permissive
vkuznet/mxnet
R
false
true
558
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/initializer.R \name{mx.init.create} \alias{mx.init.create} \title{Create initialization of argument like arg.array} \usage{ mx.init.create(initializer, shape.array, ctx, skip.unknown = TRUE) } \arguments{ \item{initializer}{The initializer.}...
rm(list = ls()) library(Daniel) library(dplyr) library(nnet) CalcCImultinom <- function(fit) { s <- summary(fit) coef <- s$coefficients ses <- s$standard.errors ci.1 <- coef[1,2] + c(-1, 1)*1.96*ses[1, 2] ci.2 <- coef[2,2] + c(-1, 1)*1.96*ses[2, 2] return(rbind(ci.1,ci.2)) } #key # A, B,C,D,E,F - betaE[2] =...
/Simulations/Scripts/R/Rare/Scenario 28/CMPEn50KrareScen28EF.R
no_license
yadevi/CausalMPE
R
false
false
4,221
r
rm(list = ls()) library(Daniel) library(dplyr) library(nnet) CalcCImultinom <- function(fit) { s <- summary(fit) coef <- s$coefficients ses <- s$standard.errors ci.1 <- coef[1,2] + c(-1, 1)*1.96*ses[1, 2] ci.2 <- coef[2,2] + c(-1, 1)*1.96*ses[2, 2] return(rbind(ci.1,ci.2)) } #key # A, B,C,D,E,F - betaE[2] =...
#!/usr/bin/env Rscript # 20200410WF - init # parse poorly quoted json string into it's own columns # reads from stdin and outputs to stdout. used by datastring2tsv inside Makefile # add additional columns derived from raw data options(warn=-1) suppressMessages({library(dplyr); library(tidyr)}) # 8=>.8, 2=>.2, 1 sta...
/analysis/readraw.R
no_license
LabNeuroCogDevel/cardtask
R
false
false
2,547
r
#!/usr/bin/env Rscript # 20200410WF - init # parse poorly quoted json string into it's own columns # reads from stdin and outputs to stdout. used by datastring2tsv inside Makefile # add additional columns derived from raw data options(warn=-1) suppressMessages({library(dplyr); library(tidyr)}) # 8=>.8, 2=>.2, 1 sta...
#microendemic species extra presence points finder setwd("/Users/nicholashuron/Dropbox/STUDENT FOLDERS/Huron, Nick/Huron_Nick_Masters/Datasets/Geographic/microendemics/") #pull in raster stack of interest env.files <- list.files(path = "/Users/nicholashuron/Dropbox/STUDENT FOLDERS/Huron, Nick/Huron_Nick_Masters/Data...
/Google Drive/Brachymeles_CA/r_code/microendemic_localities_v2.R
no_license
nahuron/thesis
R
false
false
4,864
r
#microendemic species extra presence points finder setwd("/Users/nicholashuron/Dropbox/STUDENT FOLDERS/Huron, Nick/Huron_Nick_Masters/Datasets/Geographic/microendemics/") #pull in raster stack of interest env.files <- list.files(path = "/Users/nicholashuron/Dropbox/STUDENT FOLDERS/Huron, Nick/Huron_Nick_Masters/Data...
## {poly.mod} class ## This is a class that characterizes the item response models associated with each item ## It includes a validity check between the number of models in {model} and the number ## of list elements for {items}. It also checks to make sure only acceptable values for ## {model} are includ...
/R/classes.R
no_license
zhangou888/plink
R
false
false
17,224
r
## {poly.mod} class ## This is a class that characterizes the item response models associated with each item ## It includes a validity check between the number of models in {model} and the number ## of list elements for {items}. It also checks to make sure only acceptable values for ## {model} are includ...
\alias{gtkSelectionDataSetText} \name{gtkSelectionDataSetText} \title{gtkSelectionDataSetText} \description{Sets the contents of the selection from a UTF-8 encoded string. The string is converted to the form determined by \code{selection.data->target}.} \usage{gtkSelectionDataSetText(object, str, len = -1)} \arguments{...
/man/gtkSelectionDataSetText.Rd
no_license
cran/RGtk2.10
R
false
false
721
rd
\alias{gtkSelectionDataSetText} \name{gtkSelectionDataSetText} \title{gtkSelectionDataSetText} \description{Sets the contents of the selection from a UTF-8 encoded string. The string is converted to the form determined by \code{selection.data->target}.} \usage{gtkSelectionDataSetText(object, str, len = -1)} \arguments{...
epoisMultiplyCensored.bootstrap.ci <- function (x, censored, censoring.side, est.fcn, ci.type, conf.level, n.bootstraps, obs.lambda) { N <- length(x) boot.vec <- numeric(n.bootstraps) too.few.obs.count <- 0 no.cen.obs.count <- 0 x.no.cen <- x[!censored] for (i in 1:n.bootstraps) {...
/R/epoisMultiplyCensored.bootstrap.ci.R
no_license
markocherrie/EnvStats
R
false
false
2,891
r
epoisMultiplyCensored.bootstrap.ci <- function (x, censored, censoring.side, est.fcn, ci.type, conf.level, n.bootstraps, obs.lambda) { N <- length(x) boot.vec <- numeric(n.bootstraps) too.few.obs.count <- 0 no.cen.obs.count <- 0 x.no.cen <- x[!censored] for (i in 1:n.bootstraps) {...
## BIOL 665 project EDA library(dplyr) library(geosphere) library(maps) library(rgdal) library(rgeos) #Read in BBS data ##Note: on mac once connected to Bioark server, path is "/Volumes/hurlbertlab/Databases/BBS/2017/filename.csv" routes <- read.csv("\\\\Bioark.bio.unc.edu\\hurlbertlab\\Databases\\BBS\\...
/biol665_proj_eda_script.R
no_license
gdicecco/665_proj
R
false
false
4,860
r
## BIOL 665 project EDA library(dplyr) library(geosphere) library(maps) library(rgdal) library(rgeos) #Read in BBS data ##Note: on mac once connected to Bioark server, path is "/Volumes/hurlbertlab/Databases/BBS/2017/filename.csv" routes <- read.csv("\\\\Bioark.bio.unc.edu\\hurlbertlab\\Databases\\BBS\\...
\name{calc_linked_params_BioGeoBEARS_model_object} \alias{calc_linked_params_BioGeoBEARS_model_object} \title{Update parameters that are deterministic functions of free parameters} \usage{ calc_linked_params_BioGeoBEARS_model_object(BioGeoBEARS_model_object, update_init = FALSE) } \arguments{ \item{BioGeoBEARS_...
/man/calc_linked_params_BioGeoBEARS_model_object.Rd
no_license
pedroreys/BioGeoBEARS
R
false
false
2,278
rd
\name{calc_linked_params_BioGeoBEARS_model_object} \alias{calc_linked_params_BioGeoBEARS_model_object} \title{Update parameters that are deterministic functions of free parameters} \usage{ calc_linked_params_BioGeoBEARS_model_object(BioGeoBEARS_model_object, update_init = FALSE) } \arguments{ \item{BioGeoBEARS_...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/fii_frs_interest_ref.R \name{fii_frs_interest_ref} \alias{fii_frs_interest_ref} \title{Retrieve frs interest ref data from fii database} \usage{ fii_frs_interest_ref(INTEREST_TYPE = NULL, INTEREST_DESC = NULL, PROGRAM_CATEGORY = NULL, PROGR...
/man/fii_frs_interest_ref.Rd
no_license
markwh/envirofacts
R
false
true
1,589
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/fii_frs_interest_ref.R \name{fii_frs_interest_ref} \alias{fii_frs_interest_ref} \title{Retrieve frs interest ref data from fii database} \usage{ fii_frs_interest_ref(INTEREST_TYPE = NULL, INTEREST_DESC = NULL, PROGRAM_CATEGORY = NULL, PROGR...
context("implementation [simulate.PlackettLuce]") ## Get the legacy implementation source_files <- dir(system.file("PlackettLuce0", package = "PlackettLuce"), full.names = TRUE) ## N.B. fitted0 requires tibble but unused in tests for (file0 in source_files) source(file0) R <- matrix(c(1,...
/tests/testthat/test-simulate.R
no_license
Felix660/PlackettLuce
R
false
false
2,829
r
context("implementation [simulate.PlackettLuce]") ## Get the legacy implementation source_files <- dir(system.file("PlackettLuce0", package = "PlackettLuce"), full.names = TRUE) ## N.B. fitted0 requires tibble but unused in tests for (file0 in source_files) source(file0) R <- matrix(c(1,...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/lncDIFF.R \name{lncDIFF} \alias{lncDIFF} \title{lncRNA Differential Expression (DE) analysis} \usage{ lncDIFF( edata, group, covariate = NULL, link.function = "log", CompareGroups = NULL, simulated.pvalue = FALSE, permutation = ...
/man/lncDIFF.Rd
no_license
cran/lncDIFF
R
false
true
2,177
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/lncDIFF.R \name{lncDIFF} \alias{lncDIFF} \title{lncRNA Differential Expression (DE) analysis} \usage{ lncDIFF( edata, group, covariate = NULL, link.function = "log", CompareGroups = NULL, simulated.pvalue = FALSE, permutation = ...
c DCNF-Autarky [version 0.0.1]. c Copyright (c) 2018-2019 Swansea University. c c Input Clause Count: 6178 c Performing E1-Autarky iteration. c Remaining clauses count after E-Reduction: 6178 c c Input Parameter (command line, file): c input filename QBFLIB/Biere/tipfixpoint/ken.oop^1.C-f2.qdimacs c output filena...
/code/dcnf-ankit-optimized/Results/QBFLIB-2018/E1/Experiments/Biere/tipfixpoint/ken.oop^1.C-f2/ken.oop^1.C-f2.R
no_license
arey0pushpa/dcnf-autarky
R
false
false
625
r
c DCNF-Autarky [version 0.0.1]. c Copyright (c) 2018-2019 Swansea University. c c Input Clause Count: 6178 c Performing E1-Autarky iteration. c Remaining clauses count after E-Reduction: 6178 c c Input Parameter (command line, file): c input filename QBFLIB/Biere/tipfixpoint/ken.oop^1.C-f2.qdimacs c output filena...
source("data-raw/fwa.R") source("data-raw/spatial.R") source("data-raw/eggs.R") source("data-raw/mats.R") source("data-raw/gsi.R") source("data-raw/spawners.R")
/data-raw/data-raw.R
no_license
poissonconsulting/mwstdatr
R
false
false
161
r
source("data-raw/fwa.R") source("data-raw/spatial.R") source("data-raw/eggs.R") source("data-raw/mats.R") source("data-raw/gsi.R") source("data-raw/spawners.R")
library(ISLR) attach(Auto) xyplot(acceleration~horsepower,xlab = "Horsepower",ylab = "Acceleration") library(splines) myPanel <- function(...) { panel.smooth(...) panel.xyplot(...,alpha=.5) } panel.smooth <- function(x,y,...) { knots=quantile(x,c(1/3,2/3)) fit = lm(y~bs(x,knots=knots,degree=3)) x0 = seq(m...
/assignemnt3.R
no_license
hardik-uppal/stat-class
R
false
false
8,654
r
library(ISLR) attach(Auto) xyplot(acceleration~horsepower,xlab = "Horsepower",ylab = "Acceleration") library(splines) myPanel <- function(...) { panel.smooth(...) panel.xyplot(...,alpha=.5) } panel.smooth <- function(x,y,...) { knots=quantile(x,c(1/3,2/3)) fit = lm(y~bs(x,knots=knots,degree=3)) x0 = seq(m...
############################################################################################## context("classConstructor.R : test of timeSeriesRequest method - Chunking") suppressPackageStartupMessages(require(xts)) #testDataFolder <- "tests/testthat/testData/" testDataFolder <- file.path(testthat::test_path(), "tes...
/tests/testthat/test-dsws-timeSeriesRequestChunking.R
no_license
CharlesCara/DatastreamDSWS2R
R
false
false
3,817
r
############################################################################################## context("classConstructor.R : test of timeSeriesRequest method - Chunking") suppressPackageStartupMessages(require(xts)) #testDataFolder <- "tests/testthat/testData/" testDataFolder <- file.path(testthat::test_path(), "tes...
# Code for figures to accompany 03-draft # PLOT: Age distribution ------------------------------------------------------- age_histogram <- ggplot(mockdata, aes(age)) + geom_histogram(color = 'white', fill = scico::scico(1, begin = .3, palette = "berlin"), bins = 20) + labs(x = ...
/03-graphics/R/figs.R
no_license
apreshill/r3-cloud
R
false
false
2,945
r
# Code for figures to accompany 03-draft # PLOT: Age distribution ------------------------------------------------------- age_histogram <- ggplot(mockdata, aes(age)) + geom_histogram(color = 'white', fill = scico::scico(1, begin = .3, palette = "berlin"), bins = 20) + labs(x = ...
% % Copyright (c) 2010, 2014, IBM Corp. All rights reserved. % % This program is free software: you can redistribute it and/or modify % it under the terms of the GNU General Public License as published by % the Free Software Foundation, either version 3 of the License, or % (at your option) any later version. ...
/man/idaKMeans.Rd
no_license
cran/ibmdbR
R
false
false
4,960
rd
% % Copyright (c) 2010, 2014, IBM Corp. All rights reserved. % % This program is free software: you can redistribute it and/or modify % it under the terms of the GNU General Public License as published by % the Free Software Foundation, either version 3 of the License, or % (at your option) any later version. ...
library(shiny) powered <- function(number, power) { number^power } shinyServer( function(input, output) { output$input1 <- renderPrint(input$number) output$input2 <- renderPrint(input$power) output$powered <- renderPrint(powered(input$number, input$power)) } )
/server.R
no_license
kgowda/dataproduct
R
false
false
292
r
library(shiny) powered <- function(number, power) { number^power } shinyServer( function(input, output) { output$input1 <- renderPrint(input$number) output$input2 <- renderPrint(input$power) output$powered <- renderPrint(powered(input$number, input$power)) } )
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/fit_and_reporting.R \name{umx_aggregate} \alias{umx_aggregate} \title{Convenient formula-based cross-tabs & built-in summary functions} \usage{ umx_aggregate( formula = DV ~ condition, data = df, what = c("mean_sd", "n"), digits = 2, ...
/man/umx_aggregate.Rd
no_license
tbates/umx
R
false
true
2,758
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/fit_and_reporting.R \name{umx_aggregate} \alias{umx_aggregate} \title{Convenient formula-based cross-tabs & built-in summary functions} \usage{ umx_aggregate( formula = DV ~ condition, data = df, what = c("mean_sd", "n"), digits = 2, ...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/codebuild_operations.R \name{codebuild_list_build_batches} \alias{codebuild_list_build_batches} \title{Retrieves the identifiers of your build batches in the current region} \usage{ codebuild_list_build_batches(filter, maxResults, sortOrder, ...
/cran/paws.developer.tools/man/codebuild_list_build_batches.Rd
permissive
sanchezvivi/paws
R
false
true
1,349
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/codebuild_operations.R \name{codebuild_list_build_batches} \alias{codebuild_list_build_batches} \title{Retrieves the identifiers of your build batches in the current region} \usage{ codebuild_list_build_batches(filter, maxResults, sortOrder, ...
##read the data dt<-read.table(".\\household_power_consumption.txt",sep=";",header=TRUE) ##change the class of $Date and $Time and extract components dt$Date<-as.character(dt$Date) dt$Time<-as.character(dt$Time) p<-paste(dt$Date,dt$Time) time<-unclass(as.POSIXlt(p,format="%d/%m/%Y %H:%M:%S")) ##select rows we need t0...
/plot1.R
no_license
bowang14/ExData_Plotting1
R
false
false
778
r
##read the data dt<-read.table(".\\household_power_consumption.txt",sep=";",header=TRUE) ##change the class of $Date and $Time and extract components dt$Date<-as.character(dt$Date) dt$Time<-as.character(dt$Time) p<-paste(dt$Date,dt$Time) time<-unclass(as.POSIXlt(p,format="%d/%m/%Y %H:%M:%S")) ##select rows we need t0...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/export_displacement.R \name{export_displacement} \alias{export_displacement} \title{export_displacement} \usage{ export_displacement(pca_mods_object, magnification = NULL, dimx = 0, dimy = 0, dimz = 0) } \arguments{ \item{pca_mods...
/man/export_displacement.Rd
no_license
AProfico/VoxFeR
R
false
true
838
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/export_displacement.R \name{export_displacement} \alias{export_displacement} \title{export_displacement} \usage{ export_displacement(pca_mods_object, magnification = NULL, dimx = 0, dimy = 0, dimz = 0) } \arguments{ \item{pca_mods...
library(estimatr) ### Name: difference_in_means ### Title: Design-based difference-in-means estimator ### Aliases: difference_in_means ### ** Examples library(fabricatr) library(randomizr) # Get appropriate standard errors for unit-randomized designs # ---------- # 1. Unit randomized # ---------- dat <- fabricate...
/data/genthat_extracted_code/estimatr/examples/difference_in_means.Rd.R
no_license
surayaaramli/typeRrh
R
false
false
2,988
r
library(estimatr) ### Name: difference_in_means ### Title: Design-based difference-in-means estimator ### Aliases: difference_in_means ### ** Examples library(fabricatr) library(randomizr) # Get appropriate standard errors for unit-randomized designs # ---------- # 1. Unit randomized # ---------- dat <- fabricate...
\name{slik} \alias{slik} \title{Evaluates the synthetic log-likelihood.} \usage{ slik(object, param, nsim, multicore = FALSE, ncores = detectCores() - 1, cluster = NULL, ...) } \arguments{ \item{object}{An object of class \code{synlik}.} \item{param}{Vector of parameters at which the synthetic likelihood w...
/man/slik.Rd
no_license
mfasiolo/synlik_release
R
false
false
1,551
rd
\name{slik} \alias{slik} \title{Evaluates the synthetic log-likelihood.} \usage{ slik(object, param, nsim, multicore = FALSE, ncores = detectCores() - 1, cluster = NULL, ...) } \arguments{ \item{object}{An object of class \code{synlik}.} \item{param}{Vector of parameters at which the synthetic likelihood w...
test_that("agreement coefficients match Ji and Gallo", { #' @srrstats {G5.7} Algorithm performs as expected x <- c(6, 8, 9, 10, 11, 14) y <- c(2, 3, 5, 5, 6, 8) #' @srrstats {G3.0} Testing with appropriate tolerances. #' @srrstats {G5.4c} Testing data is from the original paper. expect_equal( ww_agreem...
/tests/testthat/test-agreement_coefficient.R
permissive
ropensci/waywiser
R
false
false
3,480
r
test_that("agreement coefficients match Ji and Gallo", { #' @srrstats {G5.7} Algorithm performs as expected x <- c(6, 8, 9, 10, 11, 14) y <- c(2, 3, 5, 5, 6, 8) #' @srrstats {G3.0} Testing with appropriate tolerances. #' @srrstats {G5.4c} Testing data is from the original paper. expect_equal( ww_agreem...
# This script contains all functions needed for gene ranking project get_markers = function(sce , test = "binom", type = "all", FDR.thresh = 0.01){ # requires there is a column called celltype and assay called logcounts require(scran) # get potential relevant genes markers = scran::findMarkers(sce , groups=sce...
/functions/main_functions.R
no_license
r3fang/am_geneBasis
R
false
false
25,036
r
# This script contains all functions needed for gene ranking project get_markers = function(sce , test = "binom", type = "all", FDR.thresh = 0.01){ # requires there is a column called celltype and assay called logcounts require(scran) # get potential relevant genes markers = scran::findMarkers(sce , groups=sce...
#' @title Create a Tesselation from a Polygon #' #' @name tess2SPdf #' #' @description Returns a Spatial Polygons object from #' a Tesselation object. #' #' @export #' #' @importFrom spatstat is.tess #' @importFrom methods as #' #' @param x The Tesselation object (Tessellation) #' #' @return Returns a SpatialPolygons....
/R/tess2SPdf.R
no_license
aganbal/windfarmGA
R
false
false
1,276
r
#' @title Create a Tesselation from a Polygon #' #' @name tess2SPdf #' #' @description Returns a Spatial Polygons object from #' a Tesselation object. #' #' @export #' #' @importFrom spatstat is.tess #' @importFrom methods as #' #' @param x The Tesselation object (Tessellation) #' #' @return Returns a SpatialPolygons....
# Interact function - adapting to ranger package - use treeInfo() interact <- function(forest, depth){ ### Pass the function a random forest that has been grown through the ranger package ### ### Count the number of total occurences, average depth and number of occurences at levels 1 and 2 for each variable ...
/Interact ranger.R
no_license
MitchellOng-Thomson/Interact-ranger
R
false
false
3,654
r
# Interact function - adapting to ranger package - use treeInfo() interact <- function(forest, depth){ ### Pass the function a random forest that has been grown through the ranger package ### ### Count the number of total occurences, average depth and number of occurences at levels 1 and 2 for each variable ...
############### Student Seminar @Charite ############### ############### Dr. Joachim Krois ####################### ############### March 28, 2018 ########################## ## 03 Data analysis and tidyverse ## ======================================================== # Total number of cigarettes or cigarette equiv...
/03_smoking_blank.R
permissive
eotp/charite-seminar-2018-03-28
R
false
false
1,308
r
############### Student Seminar @Charite ############### ############### Dr. Joachim Krois ####################### ############### March 28, 2018 ########################## ## 03 Data analysis and tidyverse ## ======================================================== # Total number of cigarettes or cigarette equiv...
library(DAAG) ### Name: show.colors ### Title: Show R's Colors ### Aliases: show.colors ### Keywords: models ### ** Examples require(MASS) show.colors()
/data/genthat_extracted_code/DAAG/examples/show.colors.Rd.R
no_license
surayaaramli/typeRrh
R
false
false
160
r
library(DAAG) ### Name: show.colors ### Title: Show R's Colors ### Aliases: show.colors ### Keywords: models ### ** Examples require(MASS) show.colors()
library(shiny) shinyUI(fluidPage( titlePanel("Melting curve analysis for diagnostics"), sidebarLayout( sidebarPanel( fileInput("file","Choose .csv or .txt tab separated file to upload"), tags$hr(), checkboxInput("header","Header", TRUE), selectInput("filetype", "Select the type of file",...
/inst/AptaqPCR.gui/ui.R
no_license
NPhogat/AptaqPCR
R
false
false
2,702
r
library(shiny) shinyUI(fluidPage( titlePanel("Melting curve analysis for diagnostics"), sidebarLayout( sidebarPanel( fileInput("file","Choose .csv or .txt tab separated file to upload"), tags$hr(), checkboxInput("header","Header", TRUE), selectInput("filetype", "Select the type of file",...
# Copyright 2011 Revolution Analytics # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed...
/pkg/R/streaming.R
no_license
ruizhuhuang/rmr2
R
false
false
15,653
r
# Copyright 2011 Revolution Analytics # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed...
Print("This file was created within RStudio") print("and now it lives on GitHub")
/testing.R
no_license
rupertgoddard/RStudio-linked
R
false
false
82
r
Print("This file was created within RStudio") print("and now it lives on GitHub")
context("csem") ## Source source("test-main.R") # ============================================================================== # General tests # ============================================================================== test_that("No data/model provided causes an error", { expect_error( csem(.model = mo...
/tests/testthat/test-csem.r
no_license
HFB89/cSEM
R
false
false
10,607
r
context("csem") ## Source source("test-main.R") # ============================================================================== # General tests # ============================================================================== test_that("No data/model provided causes an error", { expect_error( csem(.model = mo...
# Test basic RxODE() invocation (including errors) library("RxODE") library("tools") # use assertError() test.dir <- tempfile("Rx_base-") dir.create(test.dir) ode <- 'd/dt(y) = r * y * (1.0 - y/K);' # ODE inside a string m1 <- RxODE(model = ode, modName = "m1", do.compile=FALSE) # ODE in a text file fn <- file....
/RxODE/tests/test-basic.R
no_license
hallowkm/RxODE
R
false
false
605
r
# Test basic RxODE() invocation (including errors) library("RxODE") library("tools") # use assertError() test.dir <- tempfile("Rx_base-") dir.create(test.dir) ode <- 'd/dt(y) = r * y * (1.0 - y/K);' # ODE inside a string m1 <- RxODE(model = ode, modName = "m1", do.compile=FALSE) # ODE in a text file fn <- file....
# W A S D # 1 1 1 1 # Ex2 # а) P(W + 5 > X ≥ min{2, A}) за сл. в. X ∼ Ge((S + D + 9)/90); # P(6 > X > min{2, 1}); X~Ge(11/90) # P(1<=x<6); [1; 6) =? 0] # P(1<=x<=5) # P(x<=5) - P(X<=0 # В дискретни разпределения равенството има значение x1 = pgeom(5, 11/90); x1 # lower.tail=TRUE (<=); FALSE: > (за интервала надясно ...
/SEM/HM2/HW2/hm2.r
no_license
valkirilov/FMI-2017-2018
R
false
false
1,679
r
# W A S D # 1 1 1 1 # Ex2 # а) P(W + 5 > X ≥ min{2, A}) за сл. в. X ∼ Ge((S + D + 9)/90); # P(6 > X > min{2, 1}); X~Ge(11/90) # P(1<=x<6); [1; 6) =? 0] # P(1<=x<=5) # P(x<=5) - P(X<=0 # В дискретни разпределения равенството има значение x1 = pgeom(5, 11/90); x1 # lower.tail=TRUE (<=); FALSE: > (за интервала надясно ...
#' Hybrid forecast #' #' Forecast method for hybrid models. #' #' @export #' @import forecast #' @import fpp #' @param object A hybrid time series model fit with hybridModel() #' @param h Number of periods for forecasting. If \code{xreg} is used, \code{h} is ignored and the number of forecast #' periods is set to th...
/forecastHybrid/R/forecast.hybridModel.R
no_license
ingted/R-Examples
R
false
false
6,267
r
#' Hybrid forecast #' #' Forecast method for hybrid models. #' #' @export #' @import forecast #' @import fpp #' @param object A hybrid time series model fit with hybridModel() #' @param h Number of periods for forecasting. If \code{xreg} is used, \code{h} is ignored and the number of forecast #' periods is set to th...
# validation by enrichment in asd2020 # take argument: gene list # return asd2020 enrichment library(optparse) option_list <- list( ## Type : logical, integer, souble complex, character make_option(c("--list"), action="store", #dimension type='character', help="gene scoring list: 1st column ge...
/scripts/validation/asd2020_120920.r
no_license
yingji15/ASD_public
R
false
false
2,100
r
# validation by enrichment in asd2020 # take argument: gene list # return asd2020 enrichment library(optparse) option_list <- list( ## Type : logical, integer, souble complex, character make_option(c("--list"), action="store", #dimension type='character', help="gene scoring list: 1st column ge...
#' Matrix containing data calculated for each growth band. #' #' A dataset containing specific parameters calculated for all interpolated #' subincrements from the Crassostrea gigas #1 oyster used as an example in de Winter #' (2017) sorted per increment. #' #' @docType data #' #' @usage data(subincr_matrix6) ...
/R/subincr_matrix6.R
no_license
cran/shelltrace
R
false
false
2,217
r
#' Matrix containing data calculated for each growth band. #' #' A dataset containing specific parameters calculated for all interpolated #' subincrements from the Crassostrea gigas #1 oyster used as an example in de Winter #' (2017) sorted per increment. #' #' @docType data #' #' @usage data(subincr_matrix6) ...
DoMCMC<-function(Xinit,DataUsed,Ndim,covar,Nsim=1000,Nburn=0,Nthin=1,prog_bar = T,run_time) { Xcurr <- Xinit Fcurr <- -1*NegLogLike2(Xcurr = Xcurr,dat = DataUsed,run_time = run_time) Outs <- matrix(0,nrow=(Nsim-Nburn),ncol=(Ndim+1)) Ipnt <- 0; Icnt <- 0 if(prog_bar == T) { pb <- txtProgressBar(min = 1...
/FISH 558 Functions/do_MCMC2.R
no_license
DanOvando/FISH-558
R
false
false
1,457
r
DoMCMC<-function(Xinit,DataUsed,Ndim,covar,Nsim=1000,Nburn=0,Nthin=1,prog_bar = T,run_time) { Xcurr <- Xinit Fcurr <- -1*NegLogLike2(Xcurr = Xcurr,dat = DataUsed,run_time = run_time) Outs <- matrix(0,nrow=(Nsim-Nburn),ncol=(Ndim+1)) Ipnt <- 0; Icnt <- 0 if(prog_bar == T) { pb <- txtProgressBar(min = 1...
# Charger les données sur la qualité de l'air library(datasets) data(airquality) # Il y a plusieurs moyens d'y arriver: mean(airquality$Solar.R[airquality$Ozone > 31 & airquality$Temp > 90],na.rm=TRUE) # Avec la fonction "subset" : pourquoi n'a-t-on pas besoin d'ajouter "na.rm=TRUE" # dans ce cas? mean(subset(airqua...
/subsets.R
no_license
calculquebec/introduction_R
R
false
false
618
r
# Charger les données sur la qualité de l'air library(datasets) data(airquality) # Il y a plusieurs moyens d'y arriver: mean(airquality$Solar.R[airquality$Ozone > 31 & airquality$Temp > 90],na.rm=TRUE) # Avec la fonction "subset" : pourquoi n'a-t-on pas besoin d'ajouter "na.rm=TRUE" # dans ce cas? mean(subset(airqua...
library(glmnet) mydata = read.table("../../../../TrainingSet/FullSet/AvgRank/upper_aerodigestive_tract.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="mae",alpha=0.3,family="gaussian",standardize=FALSE) sink('./upper_aerodig...
/Model/EN/AvgRank/upper_aerodigestive_tract/upper_aerodigestive_tract_044.R
no_license
esbgkannan/QSMART
R
false
false
384
r
library(glmnet) mydata = read.table("../../../../TrainingSet/FullSet/AvgRank/upper_aerodigestive_tract.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="mae",alpha=0.3,family="gaussian",standardize=FALSE) sink('./upper_aerodig...
# Thinkpad X1 root <- "D:\\OneDrive\\Documents\\MCMC_2\\" sourceCode <- "sourceCode\\R Model\\" workspaces <- "Workspaces\\" setwd(root) # ASUS root <- "C:\\Users\\zhiguo\\OneDrive\\Documents\\MCMC_2\\" sourceCode <- "sourceCode\\R Model\\" workspaces <- "Workspaces\\" setwd(root)
/Config.R
no_license
zhiguo-wang/MCMC_2
R
false
false
287
r
# Thinkpad X1 root <- "D:\\OneDrive\\Documents\\MCMC_2\\" sourceCode <- "sourceCode\\R Model\\" workspaces <- "Workspaces\\" setwd(root) # ASUS root <- "C:\\Users\\zhiguo\\OneDrive\\Documents\\MCMC_2\\" sourceCode <- "sourceCode\\R Model\\" workspaces <- "Workspaces\\" setwd(root)
cactus <- read.csv("ohcrapcacti.csv") ## install.packages("ggplot2") ## install.packages("dplyr") ## install.packages("caret") ## install.packages("e1071") library(dplyr) library(ggplot2) library(caret) library(e1071) colnames(cactus) cactus <- cactus %>% rename(cactus = Was.There.A.Cactus, slope = Slop...
/Cactus Walkthrough.R
no_license
inPlainR/CactusConundrum
R
false
false
1,491
r
cactus <- read.csv("ohcrapcacti.csv") ## install.packages("ggplot2") ## install.packages("dplyr") ## install.packages("caret") ## install.packages("e1071") library(dplyr) library(ggplot2) library(caret) library(e1071) colnames(cactus) cactus <- cactus %>% rename(cactus = Was.There.A.Cactus, slope = Slop...
# Advent of code 2020 # Day 7 # Load libraries library(tidyverse) # Set working directory to file location setwd(dirname(rstudioapi::getActiveDocumentContext()$path)) # Load input # Each line lists the contents allowable inside a certain type of bag. # It will either state what other bags can be inside the contai...
/solutions/day_07.R
no_license
vicnett/AOC-2020
R
false
false
3,623
r
# Advent of code 2020 # Day 7 # Load libraries library(tidyverse) # Set working directory to file location setwd(dirname(rstudioapi::getActiveDocumentContext()$path)) # Load input # Each line lists the contents allowable inside a certain type of bag. # It will either state what other bags can be inside the contai...
library(shiny) # Define UI for miles per gallon application shinyUI(pageWithSidebar( # Application title headerPanel("Imagenet Training Visulaization"), # Sidebar with controls to select the variable to plot against mpg # and to specify whether outliers should be included sidebarPanel( selectInput(...
/shinybasicfiles/ui.r
no_license
shivamnegi92/Deep-learning-Keras-Model-over-Semeion-Image-Data
R
false
false
563
r
library(shiny) # Define UI for miles per gallon application shinyUI(pageWithSidebar( # Application title headerPanel("Imagenet Training Visulaization"), # Sidebar with controls to select the variable to plot against mpg # and to specify whether outliers should be included sidebarPanel( selectInput(...
# Rscript fcc_density_heatmap_permDT_v2.R # each column => dataset; color-coded by density options(scipen = 100) set.seed(29042020) SSHFS <- FALSE setDir <- ifelse(SSHFS, "/media/electron", "") script_name <- "fcc_density_heatmap_permDT_v2.R" cat("> START ", script_name, "\n") startTime <- Sys.time() script0_name...
/FIG_1/v0_scripts_18.05/fcc_density_heatmap_permDT_v2.R
no_license
marzuf/MANUSCRIPT_FIGURES
R
false
false
10,030
r
# Rscript fcc_density_heatmap_permDT_v2.R # each column => dataset; color-coded by density options(scipen = 100) set.seed(29042020) SSHFS <- FALSE setDir <- ifelse(SSHFS, "/media/electron", "") script_name <- "fcc_density_heatmap_permDT_v2.R" cat("> START ", script_name, "\n") startTime <- Sys.time() script0_name...
install.packages (c("httr","bitops", "glue", "stringi", "pracma", "RCurl", "seismicRoll", "signal", "stringr", "XML", "readr", "lubridate", "IRISSeismic", "maps", "mapdata", "RcppArmadillo", "geojsonR"), repos = "http://cran.us.r-project.org") install.packages("maps")
/install.R
permissive
JenLowe/data-tutorials-1
R
false
false
270
r
install.packages (c("httr","bitops", "glue", "stringi", "pracma", "RCurl", "seismicRoll", "signal", "stringr", "XML", "readr", "lubridate", "IRISSeismic", "maps", "mapdata", "RcppArmadillo", "geojsonR"), repos = "http://cran.us.r-project.org") install.packages("maps")
##Plot3 ##get data fileURL <- "https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip" download.file(fileURL, destfile = "./dataset.zip", mode = "wb") unzip(zipfile="./dataset.zip", exdir="./data") ##read the data electricPowerConsumption <- read.table(./data/household_power_consumption....
/Plot3.R
no_license
schwaie/Coursera-Course-4-week-1-project
R
false
false
1,505
r
##Plot3 ##get data fileURL <- "https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip" download.file(fileURL, destfile = "./dataset.zip", mode = "wb") unzip(zipfile="./dataset.zip", exdir="./data") ##read the data electricPowerConsumption <- read.table(./data/household_power_consumption....
\name{multplot} \alias{multplot} \alias{multplot.default} \alias{multplot.fdata} \title{ Multivariate plots } \description{ Multivariate plots of Functional Data (more precisely \code{fdata} objects). } \usage{ multplot(object, ...) \method{multplot}{fdata} (object, date = 1, xval = NULL, name = NULL, ...
/man/multplot.Rd
no_license
cran/far
R
false
false
3,276
rd
\name{multplot} \alias{multplot} \alias{multplot.default} \alias{multplot.fdata} \title{ Multivariate plots } \description{ Multivariate plots of Functional Data (more precisely \code{fdata} objects). } \usage{ multplot(object, ...) \method{multplot}{fdata} (object, date = 1, xval = NULL, name = NULL, ...
c DCNF-Autarky [version 0.0.1]. c Copyright (c) 2018-2019 Swansea University. c c Input Clause Count: 11617 c Performing E1-Autarky iteration. c Remaining clauses count after E-Reduction: 11617 c c Input Parameter (command line, file): c input filename QBFLIB/Jordan-Kaiser/reduction-finding-full-set-params-k1c3n4...
/code/dcnf-ankit-optimized/Results/QBFLIB-2018/E1/Experiments/Jordan-Kaiser/reduction-finding-full-set-params-k1c3n4/query58_query36_1344/query58_query36_1344.R
no_license
arey0pushpa/dcnf-autarky
R
false
false
717
r
c DCNF-Autarky [version 0.0.1]. c Copyright (c) 2018-2019 Swansea University. c c Input Clause Count: 11617 c Performing E1-Autarky iteration. c Remaining clauses count after E-Reduction: 11617 c c Input Parameter (command line, file): c input filename QBFLIB/Jordan-Kaiser/reduction-finding-full-set-params-k1c3n4...
\name{Modigliani} \alias{Modigliani} \title{Modigliani-Modigliani measure} \usage{ Modigliani(Ra, Rb, Rf = 0, ...) } \arguments{ \item{Ra}{an xts, vector, matrix, data frame, timeSeries or zoo object of asset returns} \item{Rb}{return vector of the benchmark asset} \item{Rf}{risk free rate, in same period as ...
/man/Modigliani.Rd
no_license
guillermozbta/portafolio-master
R
false
false
1,715
rd
\name{Modigliani} \alias{Modigliani} \title{Modigliani-Modigliani measure} \usage{ Modigliani(Ra, Rb, Rf = 0, ...) } \arguments{ \item{Ra}{an xts, vector, matrix, data frame, timeSeries or zoo object of asset returns} \item{Rb}{return vector of the benchmark asset} \item{Rf}{risk free rate, in same period as ...
# R script to investigate patterns between the # average per-capita pills per year by county and # other county-level variables from US Census data # Ian Cook # 2019-07-25 library(dplyr) library(readr) library(purrr) library(broom) # load county-level pain pills data arcos_by_county <- read_csv( file = "data/arcos...
/ian/dea_pain_pills_data/code/5_model.R
no_license
ianmcook/demo_day
R
false
false
3,667
r
# R script to investigate patterns between the # average per-capita pills per year by county and # other county-level variables from US Census data # Ian Cook # 2019-07-25 library(dplyr) library(readr) library(purrr) library(broom) # load county-level pain pills data arcos_by_county <- read_csv( file = "data/arcos...
#! /Library/Frameworks/R.framework/Versions/3.1/Resources/bin/Rscript #--DSCR------- #! /opt/apps/R-2.15.2/lib64/R/bin/Rscript #--CX1-------- #! /apps/R/2.15/lib64/R/bin/Rscript ############################################################################### # # # Author: oliver ratmann # file: phdes.startme.R # # usage...
/pkg/misc/phdes.startme.R
no_license
olli0601/phylodesign
R
false
false
7,111
r
#! /Library/Frameworks/R.framework/Versions/3.1/Resources/bin/Rscript #--DSCR------- #! /opt/apps/R-2.15.2/lib64/R/bin/Rscript #--CX1-------- #! /apps/R/2.15/lib64/R/bin/Rscript ############################################################################### # # # Author: oliver ratmann # file: phdes.startme.R # # usage...
# Exercise 2: using built-in string functions # Create a variable `lyric` that contains the text "I like to eat apples and # bananas" lyric <- "I like to eat apples and bananas" # Use the `substr()` function to extract the 1st through 13th letters from the # `lyric`, and store the result in a variable called `intr...
/chapter-06-exercises/exercise-2/exercise.R
permissive
brendantran/book-exercises
R
false
false
1,388
r
# Exercise 2: using built-in string functions # Create a variable `lyric` that contains the text "I like to eat apples and # bananas" lyric <- "I like to eat apples and bananas" # Use the `substr()` function to extract the 1st through 13th letters from the # `lyric`, and store the result in a variable called `intr...
# == title # Consensus partition # # == param # -data A numeric matrix where subgroups are found by columns. # -top_value_method A single top-value method. Available methods are in `all_top_value_methods`. # Use `register_top_value_methods` to add a new top-value method. # -top_n Number of rows with ...
/R/consensus_partition.R
permissive
jokergoo/cola
R
false
false
36,379
r
# == title # Consensus partition # # == param # -data A numeric matrix where subgroups are found by columns. # -top_value_method A single top-value method. Available methods are in `all_top_value_methods`. # Use `register_top_value_methods` to add a new top-value method. # -top_n Number of rows with ...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/object-utils.R \name{save_zoo} \alias{save_zoo} \title{Save zoo object to named extension file} \usage{ save_zoo(z, file = character(0), append = FALSE, ...) } \description{ Saves a \code{\link{zoo}} object to a file with a named extension } ...
/man/save_zoo.Rd
no_license
tharte/tutils
R
false
true
1,963
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/object-utils.R \name{save_zoo} \alias{save_zoo} \title{Save zoo object to named extension file} \usage{ save_zoo(z, file = character(0), append = FALSE, ...) } \description{ Saves a \code{\link{zoo}} object to a file with a named extension } ...
suppressMessages({ library(data.table) library(faosws) library(faoswsFlag) library(faoswsUtil) library(faoswsImputation) # library(faoswsProduction) library(faoswsProcessing) library(faoswsEnsure) library(magrittr) library(dplyr) library(plyr) library(tidyr) library(sendmailR) # library(faosws...
/populationPlugin.R
no_license
SWS-Methodology/faoswsPopulation
R
false
false
17,344
r
suppressMessages({ library(data.table) library(faosws) library(faoswsFlag) library(faoswsUtil) library(faoswsImputation) # library(faoswsProduction) library(faoswsProcessing) library(faoswsEnsure) library(magrittr) library(dplyr) library(plyr) library(tidyr) library(sendmailR) # library(faosws...
library(tidyverse) library(lubridate) library(tibbletime) ############################### Question 3: Explore More #################################### ## Question 3.1 # Load data --------------------------- taxi_data <- readr::read_csv('~/Desktop/joined_taxi_data.csv') ## Question 3.2 # For each driver, identified b...
/hw1/explore_more.R
no_license
JingxinZhou/md_and_ml
R
false
false
3,110
r
library(tidyverse) library(lubridate) library(tibbletime) ############################### Question 3: Explore More #################################### ## Question 3.1 # Load data --------------------------- taxi_data <- readr::read_csv('~/Desktop/joined_taxi_data.csv') ## Question 3.2 # For each driver, identified b...
\name{MaxRsqCS} \alias{MaxRsqCS} \title{Solve for G that maximises sample r-square of X*G'*B' with X under constraints A*G<=D and Aeq*G=Deq} \usage{ MaxRsqCS(X, B, W, A = NULL, D = NULL, Aeq = NULL, Deq, lb = NULL, ub = NULL) } \arguments{ \item{X}{: [matrix] (T x N)} \item{B}{: [matrix] (T x K)} \item{W}...
/man/MaxRsqCS.Rd
no_license
runiaruni/Meucci
R
false
false
1,181
rd
\name{MaxRsqCS} \alias{MaxRsqCS} \title{Solve for G that maximises sample r-square of X*G'*B' with X under constraints A*G<=D and Aeq*G=Deq} \usage{ MaxRsqCS(X, B, W, A = NULL, D = NULL, Aeq = NULL, Deq, lb = NULL, ub = NULL) } \arguments{ \item{X}{: [matrix] (T x N)} \item{B}{: [matrix] (T x K)} \item{W}...
rm(list = ls()) start.time <- Sys.time() #Error in if (abs(adj.r.squared.train - adj.r.squared.test) < 0.01) { : #missing value where TRUE/FALSE needed #### Load packages we will use #### library(tidyverse) library(gtools) library(Metrics) library(ISLR) library(MASS) library(caret) #### Read in the data frame, ALW...
/polynomial regression WORKING with MTCars 2.R
no_license
InfiniteCuriosity/My-machine-learning-templates
R
false
false
6,493
r
rm(list = ls()) start.time <- Sys.time() #Error in if (abs(adj.r.squared.train - adj.r.squared.test) < 0.01) { : #missing value where TRUE/FALSE needed #### Load packages we will use #### library(tidyverse) library(gtools) library(Metrics) library(ISLR) library(MASS) library(caret) #### Read in the data frame, ALW...
# Code that implements the minimum interval quantile MVCI (multivariate confidence interval) #' Computes minimum width quantile CI separately for each column of matrix X i.e. #' separately for each variable #' #' Adjusts the number of observations to exclude (i.e. the percentage a in function #' f()) such that the to...
/mvci_min_interval.R
permissive
jutako/multivariate-ci
R
false
false
1,767
r
# Code that implements the minimum interval quantile MVCI (multivariate confidence interval) #' Computes minimum width quantile CI separately for each column of matrix X i.e. #' separately for each variable #' #' Adjusts the number of observations to exclude (i.e. the percentage a in function #' f()) such that the to...
args <- commandArgs() Consumption <- as.numeric(unlist(strsplit(args[2],","))) Qty <- as.numeric(unlist(strsplit(args[3],","))) year1 <- as.numeric(args[4]); day1 <- as.numeric(args[5]); sum <- as.numeric(args[6]); #return (Qty[1]) custItemCons <- ts(Qty, start=c(year1,day1),frequency = 365.25) vremenskiItem<-...
/R skripta/Rscript.r
no_license
nevena94rad/PurchaseAnalysis
R
false
false
944
r
args <- commandArgs() Consumption <- as.numeric(unlist(strsplit(args[2],","))) Qty <- as.numeric(unlist(strsplit(args[3],","))) year1 <- as.numeric(args[4]); day1 <- as.numeric(args[5]); sum <- as.numeric(args[6]); #return (Qty[1]) custItemCons <- ts(Qty, start=c(year1,day1),frequency = 365.25) vremenskiItem<-...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/ode_Til.R \name{ode_Til} \alias{ode_Til} \title{Tilman competition (2-species + resource)} \usage{ ode_Til(t, y, parms) } \arguments{ \item{t}{time (only relevant for non-autonomous ODEs, not for us, but necessary for \code{deSolve} to play n...
/man/ode_Til.Rd
no_license
cbedwards/SourCoex
R
false
true
1,643
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/ode_Til.R \name{ode_Til} \alias{ode_Til} \title{Tilman competition (2-species + resource)} \usage{ ode_Til(t, y, parms) } \arguments{ \item{t}{time (only relevant for non-autonomous ODEs, not for us, but necessary for \code{deSolve} to play n...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/utils-side.R \name{sides} \alias{sides} \title{subset the gsplot object to return only sides} \usage{ sides(gsplot) } \arguments{ \item{gsplot}{a gsplot object} } \value{ a sides list } \description{ subset the gsplot object to return only si...
/man/sides.Rd
permissive
thongsav-usgs/gsplot
R
false
true
346
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/utils-side.R \name{sides} \alias{sides} \title{subset the gsplot object to return only sides} \usage{ sides(gsplot) } \arguments{ \item{gsplot}{a gsplot object} } \value{ a sides list } \description{ subset the gsplot object to return only si...
% Generated by roxygen2 (4.1.1): do not edit by hand % Please edit documentation in R/tablechart.R \name{renderTablechart} \alias{renderTablechart} \title{Widget render function for use in Shiny} \usage{ renderTablechart(expr, env = parent.frame(), quoted = FALSE) } \description{ Widget render function for use in Shiny...
/man/renderTablechart.Rd
no_license
alteryx/AlteryxRviz
R
false
false
324
rd
% Generated by roxygen2 (4.1.1): do not edit by hand % Please edit documentation in R/tablechart.R \name{renderTablechart} \alias{renderTablechart} \title{Widget render function for use in Shiny} \usage{ renderTablechart(expr, env = parent.frame(), quoted = FALSE) } \description{ Widget render function for use in Shiny...
#'Calcula el doble de un número, es decir, lo multiplica por 2 #' #'@param x número #'@return El doble de \code{x} #'@examples #'doble(7) #'doble(8) #'@export doble <- function(x) 2 * x
/Desktop/Carpeta_Github/MiPaqueteSencillo/R/doble.R
no_license
luciaricocue/Testing_Knowledge_repo_v3
R
false
false
190
r
#'Calcula el doble de un número, es decir, lo multiplica por 2 #' #'@param x número #'@return El doble de \code{x} #'@examples #'doble(7) #'doble(8) #'@export doble <- function(x) 2 * x
library(ggplot2) library(dplyr) library(RColorBrewer) # Source error functions source(file.path(dir2, "error-fun.R")) # Load predictions #load(file.path(dir1, "strand-validation-predictions.Rdata")) load(file.path(dir1, "strand-test-predictions.Rdata")) # Load validation data #valid <- read.csv(file.path(dir1, "val...
/find-gamma.R
no_license
syq23719034/oneclass-datateam
R
false
false
2,300
r
library(ggplot2) library(dplyr) library(RColorBrewer) # Source error functions source(file.path(dir2, "error-fun.R")) # Load predictions #load(file.path(dir1, "strand-validation-predictions.Rdata")) load(file.path(dir1, "strand-test-predictions.Rdata")) # Load validation data #valid <- read.csv(file.path(dir1, "val...
validate_board <- function(b) { validate_grp_dim(nrow(b$data), ncol(b$data), b$grp_dim) } validate_grp_dim <- function(nrow, ncol, grp_dim) { } invalid_board <- function(problem, vars, ...) { if (is.character(vars)) { vars <- tick(vars) } pluralise_commas( "Column(s) ", vars, ...
/R/error.R
no_license
rtjohnson12/pseudoku
R
false
false
743
r
validate_board <- function(b) { validate_grp_dim(nrow(b$data), ncol(b$data), b$grp_dim) } validate_grp_dim <- function(nrow, ncol, grp_dim) { } invalid_board <- function(problem, vars, ...) { if (is.character(vars)) { vars <- tick(vars) } pluralise_commas( "Column(s) ", vars, ...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/fertilizers.R \name{fertilizers} \alias{fertilizers} \title{fertilizers} \usage{ fertilizers(fertilizer_quantity, coef_tbl, multiplier = NULL) } \arguments{ \item{fertilizer_quantity}{fertilizers application.} \item{coef_tbl}{coefficients.} ...
/man/fertilizers.Rd
no_license
shekharsg/nani
R
false
true
466
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/fertilizers.R \name{fertilizers} \alias{fertilizers} \title{fertilizers} \usage{ fertilizers(fertilizer_quantity, coef_tbl, multiplier = NULL) } \arguments{ \item{fertilizer_quantity}{fertilizers application.} \item{coef_tbl}{coefficients.} ...
#데이터 전처리를 위한 dplyr 공부하기 #filter() #select() #arrange() #mutate() #summartise() #group_by() #left_join() #bind_row --> rbind, cbind library(dplyr) exam <- read.csv("Doit_R/Data/csv_exam.csv") exam %>% filter(class == 1) # dlpyr 패키지에서는 %>%기호를 이용해 함수들을 나엻는 방식으로 코드를 작성한다. exam %>% filter(class %in% c(1,3,5)) # %in% 는 매치연...
/6장.R
no_license
mins0022/R_study
R
false
false
2,611
r
#데이터 전처리를 위한 dplyr 공부하기 #filter() #select() #arrange() #mutate() #summartise() #group_by() #left_join() #bind_row --> rbind, cbind library(dplyr) exam <- read.csv("Doit_R/Data/csv_exam.csv") exam %>% filter(class == 1) # dlpyr 패키지에서는 %>%기호를 이용해 함수들을 나엻는 방식으로 코드를 작성한다. exam %>% filter(class %in% c(1,3,5)) # %in% 는 매치연...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/somspa.R \name{somspa} \alias{somspa} \title{Spatial SOM} \usage{ somspa(x, ...) } \arguments{ \item{x}{A \code{sominp} object.} \item{...}{Other arguments passed to methods from \code{kohonen::som} function which is used to creat...
/man/somspa.Rd
no_license
cyenglish3/somspace
R
false
true
1,237
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/somspa.R \name{somspa} \alias{somspa} \title{Spatial SOM} \usage{ somspa(x, ...) } \arguments{ \item{x}{A \code{sominp} object.} \item{...}{Other arguments passed to methods from \code{kohonen::som} function which is used to creat...
`m4plModelShow`<- function(x, ...) { res <- NULL ID <- 1:dim(x)[1] #print("res") res <- data.frame(ID=NA,MODEL=NA,LL=NA,AIC=NA,BIC=NA,T=0,SeT=NA,S=0,SeS=NA,C=0,SeC=NA,D=0,SeD=NA) #print("T") temp1 <- m4plPersonParameters(x=x, model="T", more=TRUE, ...) temp2 <- m4plMoreSummary(temp1, out="result") t...
/irtProb/R/m4plModelShow.r
no_license
ingted/R-Examples
R
false
false
2,958
r
`m4plModelShow`<- function(x, ...) { res <- NULL ID <- 1:dim(x)[1] #print("res") res <- data.frame(ID=NA,MODEL=NA,LL=NA,AIC=NA,BIC=NA,T=0,SeT=NA,S=0,SeS=NA,C=0,SeC=NA,D=0,SeD=NA) #print("T") temp1 <- m4plPersonParameters(x=x, model="T", more=TRUE, ...) temp2 <- m4plMoreSummary(temp1, out="result") t...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/selectPolys.r \name{selectPolys} \alias{selectPolys} \title{Interactively select spatial polygons to query or filter data} \usage{ selectPolys(type = "au") } \arguments{ \item{type}{One of 'au', 'huc8', or 'huc12' to select assessment unit, H...
/man/selectPolys.Rd
permissive
utah-dwq/wqTools
R
false
true
659
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/selectPolys.r \name{selectPolys} \alias{selectPolys} \title{Interactively select spatial polygons to query or filter data} \usage{ selectPolys(type = "au") } \arguments{ \item{type}{One of 'au', 'huc8', or 'huc12' to select assessment unit, H...
#s_shaped_growth.R library(deSolve) library(ggplot2) library(gridExtra) SimTime <- seq(0, 100, 0.25) Stocks <- c(Stock = 100) Auxs <- c( Capacity = 10000, RefAvailability = 1, RefGrowthRate = 0.1 ) Model <- function(Time, Stocks, Auxs) { with(as.list(c(Stocks, Auxs)), { Availability <- 1 - Stock / Capaci...
/sys_dyn_in_r/s_shaped_growth.R
no_license
gregorbj/R-Systems-Dynamics
R
false
false
742
r
#s_shaped_growth.R library(deSolve) library(ggplot2) library(gridExtra) SimTime <- seq(0, 100, 0.25) Stocks <- c(Stock = 100) Auxs <- c( Capacity = 10000, RefAvailability = 1, RefGrowthRate = 0.1 ) Model <- function(Time, Stocks, Auxs) { with(as.list(c(Stocks, Auxs)), { Availability <- 1 - Stock / Capaci...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/centroid.R \name{centroid} \alias{centroid} \title{Iterative algorithm to determine the center of a polygon find the center of mass / furthest away from any boundary Takes as input a spatial polygon} \arguments{ \item{pol}{One or more polygo...
/man/centroid.Rd
no_license
geneorama/geneorama
R
false
true
685
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/centroid.R \name{centroid} \alias{centroid} \title{Iterative algorithm to determine the center of a polygon find the center of mass / furthest away from any boundary Takes as input a spatial polygon} \arguments{ \item{pol}{One or more polygo...
######################################### # Visual Depiction of Heteroskedasticity ######################################### library(ggplot2) set.seed(15) x1 <- order(rnorm(200, mean = 100, sd = 25)) y <- sapply(x1, function(x) {17+1.8*x + rnorm(1,mean=0, sd = x/4)}) df <- data.frame(x1 = x1, y = y) fit<-coef(lm(y ~ x...
/book/packt/Mastering.Predictive.Analytics.with.R/chapter2.R
no_license
xenron/sandbox-da-r
R
false
false
9,808
r
######################################### # Visual Depiction of Heteroskedasticity ######################################### library(ggplot2) set.seed(15) x1 <- order(rnorm(200, mean = 100, sd = 25)) y <- sapply(x1, function(x) {17+1.8*x + rnorm(1,mean=0, sd = x/4)}) df <- data.frame(x1 = x1, y = y) fit<-coef(lm(y ~ x...
#### roxygen2 comments ################################################ # #' Exponential Gradient Algorithm (UP) #' #' computes the Exponential Gradient Algorithm by Helmbold et al., 1998 #' #' @param returns Matrix of price relatives, i.e. the ratio of the closing #' (opening) price today and the day ...
/R/alg_EG.R
permissive
smhjn/olpsR
R
false
false
2,428
r
#### roxygen2 comments ################################################ # #' Exponential Gradient Algorithm (UP) #' #' computes the Exponential Gradient Algorithm by Helmbold et al., 1998 #' #' @param returns Matrix of price relatives, i.e. the ratio of the closing #' (opening) price today and the day ...
# Creating a navlink nav_links <- tags$ul( tags$li( tags$a(href = "/", "home"), ), tags$li( tags$a(href = "/login", "login"), ), tags$li( tags$a(href = "/logout", "logout"), ) )
/golembrochure/R/utils.R
no_license
tisseuil/golemexamples
R
false
false
205
r
# Creating a navlink nav_links <- tags$ul( tags$li( tags$a(href = "/", "home"), ), tags$li( tags$a(href = "/login", "login"), ), tags$li( tags$a(href = "/logout", "logout"), ) )
#' @rdname security_groups #' @title Security Groups #' @description Describe, create, and delete Security Groups #' @param name A character string (max 255 characters) specifying a security group name. #' @param id A character string specifying a security group ID. #' @param description A character string specifying a...
/R/SecurityGroups.r
no_license
CDC/aws.ec2
R
false
false
1,926
r
#' @rdname security_groups #' @title Security Groups #' @description Describe, create, and delete Security Groups #' @param name A character string (max 255 characters) specifying a security group name. #' @param id A character string specifying a security group ID. #' @param description A character string specifying a...
library(dplyr) library(magrittr) library(rpart) library(RWeka) #library(caret) library(e1071) library(ROCR) library(randomForest) #Read the German Credit Dataset credit_data <- as.data.frame(read.csv("GermanCredit_assgt.csv")) str(credit_data)setwd attach(credit_data) #Proportion of 0's and 1's in the...
/Trees.R
no_license
bparasar/Fraud-Detection
R
false
false
5,234
r
library(dplyr) library(magrittr) library(rpart) library(RWeka) #library(caret) library(e1071) library(ROCR) library(randomForest) #Read the German Credit Dataset credit_data <- as.data.frame(read.csv("GermanCredit_assgt.csv")) str(credit_data)setwd attach(credit_data) #Proportion of 0's and 1's in the...
#' Rcpp Sugar -- sort_unique #' #' This function implements the Rcpp sugar function \code{sort_unique}. #' @param x a vector of storage mode: character, double, integer #' @export sugar_sort_unique <- function(x) { types <- typeof(x) switch( types, character=.Call( "RcppSugar_sort_unique_character", x, PACKAGE...
/B_analysts_sources_github/kevinushey/RcppSugar/sort_unique.R
no_license
Irbis3/crantasticScrapper
R
false
false
524
r
#' Rcpp Sugar -- sort_unique #' #' This function implements the Rcpp sugar function \code{sort_unique}. #' @param x a vector of storage mode: character, double, integer #' @export sugar_sort_unique <- function(x) { types <- typeof(x) switch( types, character=.Call( "RcppSugar_sort_unique_character", x, PACKAGE...
# All data and CER parameters are preloaded in your workspace. # Type "ls()" in the console to see them. # Annual risk-free rate of 3% per year for the T-bill t_bill_rate = 0.03 # Set of tangency portfolio weights tangency_weights = seq(from=0, to=2, by=0.1) # Portfolio parameters mu_portfolio_tangency_bill = t_bill...
/Finance/CompuationalFinance-R/Lab_78.R
no_license
ymlai87416/PythonPlayground
R
false
false
1,043
r
# All data and CER parameters are preloaded in your workspace. # Type "ls()" in the console to see them. # Annual risk-free rate of 3% per year for the T-bill t_bill_rate = 0.03 # Set of tangency portfolio weights tangency_weights = seq(from=0, to=2, by=0.1) # Portfolio parameters mu_portfolio_tangency_bill = t_bill...
rm(list=ls()) library(data.table) library(RPostgres) wrds <- dbConnect(Postgres(), host='wrds-pgdata.wharton.upenn.edu', port=9737, sslmode='require', dbname='wrds') #------------------------------- # Tables names in CRSPQ schema #--------------...
/CRSP/pgms/basic_query.R
no_license
blake-marsh/WRDS_tools
R
false
false
1,297
r
rm(list=ls()) library(data.table) library(RPostgres) wrds <- dbConnect(Postgres(), host='wrds-pgdata.wharton.upenn.edu', port=9737, sslmode='require', dbname='wrds') #------------------------------- # Tables names in CRSPQ schema #--------------...
# Copyright Mark Niemann-Ross, 2018 # Author: Mark Niemann-Ross. mark.niemannross@gmail.com # LinkedIn: https://www.linkedin.com/in/markniemannross/ # Github: https://github.com/mnr # More Learning: http://niemannross.com/link/mnratlil # Description: subsampling data # sample() ---------------------------------------...
/Chapter 02/02_05_subsample.R
no_license
mnr/R-for-Data-Science-High-Volume
R
false
false
2,469
r
# Copyright Mark Niemann-Ross, 2018 # Author: Mark Niemann-Ross. mark.niemannross@gmail.com # LinkedIn: https://www.linkedin.com/in/markniemannross/ # Github: https://github.com/mnr # More Learning: http://niemannross.com/link/mnratlil # Description: subsampling data # sample() ---------------------------------------...
#' @rdname postgres-tables #' @usage NULL dbWriteTable_PqConnection_character_data.frame <- function(conn, name, value, ..., row.names = FALSE, overwrite = FALSE, append = FALSE, field.types = NULL, temporary = FALSE, copy = NULL) { if (is.null(row.names)) ro...
/R/dbWriteTable_PqConnection_character_data.frame.R
permissive
r-dbi/RPostgres
R
false
false
3,160
r
#' @rdname postgres-tables #' @usage NULL dbWriteTable_PqConnection_character_data.frame <- function(conn, name, value, ..., row.names = FALSE, overwrite = FALSE, append = FALSE, field.types = NULL, temporary = FALSE, copy = NULL) { if (is.null(row.names)) ro...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/06BibEntry.R \name{BibEntry} \alias{BibEntry} \title{Enhanced Bibliographic Entries} \usage{ BibEntry( bibtype, textVersion = NULL, header = NULL, footer = NULL, key = NULL, ..., other = list(), mheader = NULL, mfooter = NUL...
/man/BibEntry.Rd
no_license
palderman/RefManageR
R
false
true
7,536
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/06BibEntry.R \name{BibEntry} \alias{BibEntry} \title{Enhanced Bibliographic Entries} \usage{ BibEntry( bibtype, textVersion = NULL, header = NULL, footer = NULL, key = NULL, ..., other = list(), mheader = NULL, mfooter = NUL...
#Course Project #Set working directory setwd("P:/Data Science/Coursera/Getting and Cleaning Data") getwd() #1. Merge the training and the test sets to create one data set. #Import data sets train <- read.table("./UCI HAR Dataset/train/X_train.txt") train.activity <- read.table("./UCI HAR Dataset/train/y_train.txt") ...
/run_analysis.R
no_license
glinskyih/GettingandCleaningData
R
false
false
2,674
r
#Course Project #Set working directory setwd("P:/Data Science/Coursera/Getting and Cleaning Data") getwd() #1. Merge the training and the test sets to create one data set. #Import data sets train <- read.table("./UCI HAR Dataset/train/X_train.txt") train.activity <- read.table("./UCI HAR Dataset/train/y_train.txt") ...
# Part of the rstap package for estimating model parameters # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 3 # of the License, or (at your option) any later version. # # This...
/R/stapreg2.R
no_license
Biostatistics4SocialImpact/rstap2
R
false
false
1,629
r
# Part of the rstap package for estimating model parameters # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 3 # of the License, or (at your option) any later version. # # This...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/reg_logit.R \name{reg_logistic} \alias{reg_logistic} \title{regress for logistic regression using glm} \usage{ reg_logistic(data, y, x) } \arguments{ \item{data}{data} \item{y}{y} \item{x}{x, missing means all the rest variable...
/man/reg_logistic.Rd
no_license
yikeshu0611/onetree
R
false
true
449
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/reg_logit.R \name{reg_logistic} \alias{reg_logistic} \title{regress for logistic regression using glm} \usage{ reg_logistic(data, y, x) } \arguments{ \item{data}{data} \item{y}{y} \item{x}{x, missing means all the rest variable...
# Loading packages library(dplyr) library(ggplot2) # Read data files # read national emissions data NEI <- readRDS("exdata-data-NEI_data/summarySCC_PM25.rds") # str(NEI) # dim(NEI) # head(NEI) #read source code classification data SCC <- readRDS("exdata-data-NEI_data/Source_Classification_Code.rds") # str(...
/plot4.R
no_license
datasci201195/EDA_Airquality
R
false
false
1,381
r
# Loading packages library(dplyr) library(ggplot2) # Read data files # read national emissions data NEI <- readRDS("exdata-data-NEI_data/summarySCC_PM25.rds") # str(NEI) # dim(NEI) # head(NEI) #read source code classification data SCC <- readRDS("exdata-data-NEI_data/Source_Classification_Code.rds") # str(...