dan mackinlay avatar dan mackinlay committed a759105

light refactor

Comments (0)

Files changed (2)

.Rhistory

-array(us, dim=c(10000))
-es=array(us, dim=c(10000))
-es
-quantile(es, probs=seq(0,1,1/64))
-plot(quantile(es, probs=seq(0,1,1/64)))
-pts=seq(0,1,1/64)
-plot(quantile(es, probs=pts))
-plot(full.quantile, pts)
-full.quantile.10 = function (q) {full.quantile(q,10)}
-fix(full.quantile)
-plot(quantile(es, probs=pts))
-lines(full.quantile, pts)
-lines(full.quantile)pts), pts)
-lines(full.quantile(pts), pts)
-plot(quantile(es, probs=pts))
-plot(full.quantile, pts)
-full.quantile.10 = function (q) {full.quantile(q,10)}
-plot(full.quantile, pts)
-plot(full.quantile.10, pts)
-lines(full.quantile.10(pts), pts)
-plot(full.quantile.10, pts)
-full.quantile.10(pts)
-pts
-lines(full.quantile.10(pts), pts)
-lines(pts, full.)
-lines(pts,full.quantile.10(pts))
-plot(quantile(es, probs=pts))
-lines(pts,full.quantile.10(pts))
-plot(quantile(es, probs=pts),pts)
-plot(pts, quantile(es, probs=pts))
-lines(pts,full.quantile.10(pts))
-lines(pts,full.quantile(pts, 1))
-pts,full.quantile(pts, 10)
-full.quantile(pts, 10)
-for d in seq(1,10){lines(pts,full.quantile(pts, d))
-for (d in seq(1,10)) {lines(pts,full.quantile(pts, d))
-)
-for (d in seq(1,10)) {lines(pts,full.quantile(pts, d))}
-for (d in seq(2,10)) {lines(pts,full.quantile(pts, d))}
-for (d in seq(2,100)) {lines(pts,full.quantile(pts, d))}
-fix(full.quantile)
-fix(half.quantile)
-cats
-anova(linfit.interactey, linfit.unsexed)
-anova(linfit.interactey
-)
-anova(linfit.unsexed, linfit.interactey)
-sample(cats)
-sample(cats)
-sample(cats)
-sample(cats)
-sample(cats)
-sample(cats)
-sample(cats)
-sample(cats)
-cats[1]
-size(cats)
-length(cats)
-length(cats[1])
-length(cats[2])
-cats
-summary(cats)
-ncol(cats)
-sample.int(ncol(cats))
-sample.int(nrow(cats))
-sample.int(nrow(cats), replace=Tr)
-sample.int(nrow(cats), replace=TRUE)
-cats[,2]
-cats[2,]
-cats[[2,]]
-cats[[2]]
-cats[[,2]]
-cats[2,]
-cats[c(2,3),]
-resample.cats = function () {
-rows = sample.int(nrow(cats), replace=TRUE)
-return(cats(rows,))
-}
-resample.cats
-resample.cats()
-cats
-nrow(cats)
-resample.cats = function () {
-rows = sample.int(nrow(cats), replace=TRUE)
-}
-resample.cats()
-resample.cats = function () {
-rows = sample.int(nrow(cats), replace=TRUE)
-return(cats[rows,)]
-return(cats[rows,])
-resample.cats = function () {
-rows = sample.int(nrow(cats), replace=TRUE)
-return(cats[rows,])
-}
-resample.cats()
-resample.cats()
-resample.cats()
-resample.cats()
-resample.cats()
-summary(resample.cats())
-summary(resample.cats())
-summary(cats)
-lm(Hwt ~ Bwt * Sex, data=cats)
-lm(Hwt ~ 0+ Bwt * Sex)
-lm(Hwt ~ 0+ Bwt * Sex, data=cats)
-lm(Hwt ~ 0 + Bwt, data=newdata)
-lm(Hwt ~ 0 + Bwt, data=cats)
-coeff(lm(Hwt ~ 0 + Bwt, data=cats))
-coef(lm(Hwt ~ 0 + Bwt, data=cats))
-coef(lm(Hwt ~ 0 + Bwt, data=cats))$Bwt
-coef(lm(Hwt ~ 0 + Bwt, data=cats))
-coef(lm(Hwt ~ 0 + Bwt, data=cats))[0]
-coef(lm(Hwt ~ 0 + Bwt, data=cats))*43
-fit.cats.1 = function(newdata) { coef(lm(Hwt ~ 0 + Bwt, data=cats))}
-fit.cats.1(resample.cats())
-fit.cats.1(resample.cats())
-fit.cats.1(resample.cats())
-fit.cats.1(resample.cats())
-fit.cats.1(resample.cats())
-rep(fit.cats.1(resample.cats()), 1000)
-rep(fit.cats.1(resample.cats()), 10000)
-se(rep(fit.cats.1(resample.cats()), 10000))
-sd(rep(fit.cats.1(resample.cats()), 10000))
-replicate(fit.cats.1(resample.cats()), 10000)
-replicate(1000, fit.cats.1(resample.cats()))
-sd(replicate(1000, fit.cats.1(resample.cats())))
-hist(sample.int(nrow(cats), replace=TRUE), plot=TRUE)
-hist(sample.int(nrow(cats), replace=TRUE), plot=TRUE)
-hist(sample.int(nrow(cats), replace=TRUE), plot=TRUE)
-hist(sample.int(nrow(cats), replace=TRUE), plot=TRUE)
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-plot(full.quantile)
-plot(full.quantile,pts)
-plot(full.quantile,pts)
-plot(full.quantile(pts),pts)
-plot(full.quantile(pts, d=2),pts)
-lines(full.quantile(pts, d=2),pts)
-clf
-lines(full.quantile(pts, d=2),pts)
-plot.new
-plot.new()
-lines(full.quantile(pts, d=2),pts)
-curve(full.quantile)
-curve(full.quantile, d=1)
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-curve(full.quantile, d=1)
-curve(full.quantile)
-mypalette<-brewer.pal(7,"Greens")
-library(RColorBrewer)
-mypalette<-brewer.pal(7,"Greens")
-mypalette<-brewer.pal(9,"Greens")
-full.quantile(pts)
-apply
-()
-outer(pts, seq(2,9), full.quantile)
-outer(pts, seq(2,9,1), full.quantile)
-outer(pts, seq(2,9,by=1), full.quantile)
-outer(pts, seq(2,9), full.quantile)
-vals=data.frame(outer(pts, seq(2,9), full.quantile))
-colnames(vals) = seq(2,9)
-vals
-colnames(vals) = seq(2,10)
-dims = seq(2,10)
-outer(pts, dims, full.quantile)
-colnames(vals) = dims
-vals=data.frame(outer(pts, dims, full.quantile))
-dims = seq(2,10)
-colnames(vals) = dims
-vla
-vals
-length(dims)
-vals[,2]
-vals[,1]
-vals[,0]
-source('~/src/me/bubble_economy/quantile_plots.R')
-pts = seq(0,1,1/128)
-dims = seq(2,10)
-ndims = length(dims)
-vals=data.frame(outer(pts, dims, full.quantile))
-# get the range for the x and y axis
-xrange <- c(0,1)
-yrange <- c(-1,1)
-pts = seq(0,1,1/128)
-dims = seq(2,10)
-ndims = length(dims)
-vals=data.frame(outer(pts, dims, full.quantile))
-# get the range for the x and y axis
-xrange = c(0,1)
-yrange = c(-1,1)
-colors = brewer.pal(ndims,"Greens")
-# set up the plot
-plot(xrange, yrange, type="F", xlab="x",
-ylab="quantile" )
-line
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-pts
-vals[,1]
-vals[10]
-vals[9]
-vals$1
-vals$2
-paste(2)
-paste(c(2,2)
-)
-seq(3)
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-half.quantile = function(x,d=3) {
-g=qf(x,d-1,1)
-return(1/sqrt(g*(d-1)+1))
-}
-full_quantile = function (x, d=3) {
-x.scaled = 2*x -1
-res = sign(x.scaled)*half.quantile(1-abs(x.scaled), d)
-return(res)
-}
-pts = seq(0,1,1/128)
-dims = paste(seq(2,10))
-ndims = length(dims)
-vals=data.frame(outer(pts, dims, full.quantile))
-# get the range for the x and y axis
-xrange = c(0,1)
-yrange = c(-1,1)
-colors = brewer.pal(ndims,"Greens")
-# set up the plot
-plot(xrange, yrange, type="l", xlab="x",
-ylab="quantile")
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-display.brewer.all
-display.brewer.all ()
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-source('~/src/me/bubble_economy/quantile_plots.R')
-library(RColorBrewer)
-vs = matrix(rnorm(n=4620), nrow=10)
-us = apply(vs, 2, function(v) v/sqrt(sum(v^2)))
-es=array(us, dim=c(4620))
-points(pts, quantile)
-points(pts, quantile(es,pts))
-vs = matrix(rnorm(n=4620), nrow=3)
-us = apply(vs, 2, function(v) v/sqrt(sum(v^2)))
-es=array(us, dim=c(4620))
-points(pts, quantile(es,pts))
-source('~/src/me/cs-36-402/homework 5/q5.R')
-source('~/src/me/cs-36-402/homework 5/q5.R')
-resample.cats
-resample.cats()
-fit.cats.1(resample.cats())
-fit.cats.1(resample.cats())
-fit.cats.1(resample.cats())
-fit.cats.1(resample.cats())
-fit.cats.1(resample.cats())
-fit.cats.1(resample.cats())
-fit.cats.1(cats
-)
-rep(1000, fit.cats.1)
-rep(1000, fit.cats.1())
-rep(1000, fit.cats.1(resample.cats))
-rep(1000, fit.cats.1(resample.cats()))
-rep(fit.cats.1(resample.cats()), 1000)
-replicate(fit.cats.1(resample.cats()), 1000)
-replicate(1000,fit.cats.1(resample.cats()))
-source('~/src/me/cs-36-402/homework 5/q5.R')
-source('~/src/me/cs-36-402/homework 5/q5.R')
-cats.1.se
-cats.1.se(100)
-cats.1.se(100)
-cats.1.se(1000)
-source('~/src/me/cs-36-402/homework 5/q5.R')
-cats.1.cis(1000)
-source('~/src/me/cs-36-402/homework 5/q5.R')
-cats.1.cis(1000)
-cats.1.cis(.95, 1000)
-cats.1.cis(.05, 1000)
-anova(linfit.unsexed, linfit.interactey)
-linfit.unsexed
-summaru(linfit.unsexed)
-summary(linfit.unsexed)
-cats.1.cis(.05, 1000)
-glm(Hwt~ 0 +Bwt, data=cats)
-glm(Hwt~ 0 +Bwt+Sex, data=cats)
-glm(Hwt~ 0 +Bwt+as.numeric(Sex), data=cats)
-glm(Hwt~ 0 +Bwt+as.numeric(Sex)-1, data=cats)
-glm(Hwt~ 0 +Bwt+(as.numeric(Sex)-1), data=cats)
-cats$SexN=as.numeric(cats$Sex)-1
-cats$SexN
-glm(Hwt~ 0 +Bwt+(as.numeric(Sex)-1), data=cats)
-glm(Hwt~ 0 +Bwt+SexN, data=cats)
-glm(Hwt~ 0 +Bwt, data=cats)
-library(boot)
-cv.glm(cats,glm(Hwt~ 0 +Bwt, data=cats), K=5)
-delta.unsexed = cv.glm(cats,glm(Hwt~ 0 +Bwt, data=cats), K=5)$delta
-delta.interactey = cv.glm(cats,glm(Hwt~ 0 +Bwt+SexN, data=cats), K=5)$delta
-delta.interactey
-delta.sexed
-delta.unsexed
-source('~/src/me/bubble_economy/quantile_plots.R')
-plot.new
-plot.new()
-source('~/src/me/bubble_economy/quantile_plots.R')
-library(RColorBrewer)
-source('~/src/me/bubble_economy/quantile_plots.R')
-curve(half.quantile)
-half.4=function(x,d){half.quantile(x,4)}
-curve(half.4)
-source('~/src/me/bubble_economy/quantile_plots.R')
-curve(half.quantile)
-curve(half.4)
-source('~/src/me/bubble_economy/quantile_plots.R')
-trials = read.csv(file="Data/experiments/text/reparameterized2-1500.tsv")
-trials
-smay(tris)
-summary(trials)
-trials = read.csv(file="Data/experiments/text/reparameterized2-1500.tsv",sep='\t')
-summary(trials)
-trials$P1
-summary(trials)
-table(trails$stat_name)
-table(trials$stat_name)
-table(trials$stat_name)[0]
-summary(table(trials$stat_name))
-case.names(table(trials$stat_name))
-trial.stat.names = case.names(table(trials$stat_name))
-summary(trial.stat.names)
-names(trials)
-trials[stat_name==trial.stat.names[1]]
-trials[stat_name == trial.stat.names[1]]
-trials[stat_name == "vel_loc_self_mi_apriori_piecewise_wicks.tree_mi_raw.multiplicity"
-[54] "vel_loc_self_mi_apriori_piecewise_wicks.tree_mi_raw.std_dev"
-trials[stat_name == "vel_loc_self_mi_apriori_piecewise_wicks.tree_mi_raw.multiplicity"]
-trials$stat_name
-attach("trials")
-attach(trials)
-trials[stat_name == trial.stat.names[1]]
-trials[stat_name == trial.stat.names[1],]
-summary(trials[stat_name == trial.stat.names[1],])
-this.stat = trials[stat_name == trial.stat.names[1],]
-boxplot(count ~ spray, data = InsectSprays, col = "lightgray")
-boxplot(count ~ spray, data = InsectSprays,
-notch = TRUE, add = TRUE, col = "blue")
-range(this.stat)
-range(this.stat$stat_value)
-max(this.stat$stat_value)
-max(this.stat$P1)
-range(this.stat$P1)
-xrange=range(this.stat$P1)
-yrange = c(0, max(this.stat$stat_value))
-plot(xrange, yrange, type="n")
-table(this.stat$P2)
-size(table(this.stat$P2))
-length(table(this.stat$P2))
-colors = rainbow(length(table(this.stat$P2)))
-n.lines = length(table(this.stat$P2))
-colors = rainbow(n.lines)
-plotchar = seq(18, 18+n.lines,1)
-for (i in 1:n.lines) {}
-for (i in 1:n.lines) {
-this.line = subset(this.stat)
-}
-table(this.stat)
-table(this.stat$P1)
-table(this.stat$P2)
-summary(table(this.stat$P2))
-names(table(this.stat$P2))
-table(this.stat$P2)[0]
-table(this.stat$P2)[2]
-table(this.stat$P2)[1]
-z.vals = names(table(this.stat$P2))
-for (i in 1:n.lines) {
-this.line = subset(this.stat, this.stat$P2==zvals[i])
-lines(this.stat$P1, this.stat$stat_Value, type = b, lty=linetype[i], col=colors[i], pch=plotchar[i])
-}
-for (i in 1:n.lines) {
-this.line = subset(this.stat, this.stat$P2==z.vals[i])
-lines(this.stat$P1, this.stat$stat_Value, type = b, lty=linetype[i], col=colors[i], pch=plotchar[i])
-}
-for (i in 1:n.lines) {
-this.line = subset(this.stat, this.stat$P2==z.vals[i])
-lines(this.line$P1, this.line$stat_Value, type = "b"", lty=linetype[i], col=colors[i], pch=plotchar[i])
-}
-)
-}
-})))}}}}
-;
-)
-}
-""
-for (i in 1:n.lines) {
-this.line = subset(this.stat, this.stat$P2==z.vals[i])
-lines(this.line$P1, this.line$stat_Value, type = "b", lty=linetype[i], col=colors[i], pch=plotchar[i])
-}
-linetype
-source('~/src/me/bubble_economy/plot_mi.R')
-n.lines=1
-for (i in 1:n.lines) {
-this.line = subset(this.stat, this.stat$P2==z.vals[i])
-lines(this.line$P1, this.line$stat_Value, type = "b", lty=linetype[i], col=colors[i], pch=plotchar[i])
-}
-plot(xrange, yrange, type="n")
-for (i in 1:n.lines) {
-this.line = subset(this.stat, this.stat$P2==z.vals[i])
-lines(this.line$P1, this.line$stat_Value, type = "b", lty=linetype[i], col=colors[i], pch=plotchar[i])
-}
-this.stat
-for (i in 1:n.lines) {
-this.line = subset(this.stat, this.stat$P2==z.vals[i])
-lines(this.line$P1, this.line$stat_Value, type = "b", lty=linetype[i], col=colors[i], pch=plotchar[i])
-}subset(this.stat, this.stat$P2==z.vals[i])
-subset(this.stat, this.stat$P2==z.vals[i])
-for (i in 1:n.lines) {
-this.line = subset(this.stat, this.stat$P2==z.vals[i])
-lines(this.line$P1, this.line$stat_value, type = "b", lty=linetype[i], col=colors[i], pch=plotchar[i])
-}
-order(this.line, this.line$P2)
-order(this.line$P2, this.line$P1)
-order(this.stat$P2, this.stat$P1)
-trials[stat_name == trial.stat.names[1],][order(this.stat$P2, this.stat$P1)]
-trials[stat_name == trial.stat.names[1],][order(this.stat$P2, this.stat$P1),]
-source('~/src/me/bubble_economy/plot_mi.R')
-this.stat = trials[stat_name == trial.stat.names[1],]
-this.stat = this.stat[order(this.stat$P2, this.stat$P1),]
-this.stat = this.stat[order(this.stat$P2, this.stat$P1),]
-xrange=range(this.stat$P1)
-yrange = c(0, max(this.stat$stat_value))
-plot(xrange, yrange, type="n")
-z.vals = names(table(this.stat$P2))
-n.lines = length(z.vals)
-colors = rainbow(n.lines)
-plotchar = seq(18, 18+n.lines,1)
-linetype <- c(1:n.lines)
-i=1
-this.line = subset(this.stat, this.stat$P2==z.vals[i])[sort.order]
-this.line = subset(this.stat, this.stat$P2==z.vals[i])
-lines(this.line$P1, this.line$stat_value, type = "b", lty=linetype[i], col=colors[i], pch=plotchar[i])
-plot(xrange, yrange, type="n", xlab="P1", ylab="P2")
-source('~/src/me/bubble_economy/plot_mi.R')
-trial.stat.names[1]
-source('~/src/me/bubble_economy/plot_mi.R')
-source('~/src/me/bubble_economy/plot_mi.R')
-trial.stat.names
-plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_wicks.tree_mi_raw.mean")
-plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_wicks.tree_mi_raw.mean")
-plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_wicks.tree_mi_raw.mean")
-source('~/src/me/bubble_economy/plot_mi.R')
-plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_wicks.tree_mi_raw.mean")
-trial.stat.names[1]
-trial.stat.names
-plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_cochrane.tree_mi_raw.mean")
-plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_cochrane.tree_mi_raw.mean")
-plot.stat(stat.name ="vel_loc_self_mi_apriori_complete_cochrane.tree_mi_raw.mean")
-plot.stat(stat.name ="vel_loc_self_mi_apriori_piecewise_cochrane.tree_mi_raw.mean")
-plot.stat(stat.name ="vel_loc_self_mi_apriori_piecewise_cochrane.tree_mi_raw.mean")
-plot.stat(stat.name ="vel_loc_self_mi_apriori_piecewise_cochrane.mean_mi.mean")
-plot.stat(stat.name ="vel_loc_self_mi_apriori_piecewise_cochrane.mean_mi.mean")
-trials["P1"]
-trial.stat.names
-plot.stat(stat.name ="susceptibility_continuous.est.multiplicity"")
-""
-plot.stat(stat.name ="susceptibility_continuous.est.multiplicity")
-plot.stat(stat.name ="susceptibility_piecewise.est.multiplicity")
-trial.stat.names
-plot.stat(stat.name = "order_continuous.est.std_dev")
-source('~/src/me/bubble_economy/plot_mi.R')
-plot.stat(stat.name = "order_continuous.est.std_dev")
-source('~/src/me/bubble_economy/plot_mi.R')
-plot.stat(stat.name = "order_continuous.est.std_dev")
-source('~/src/me/bubble_economy/plot_mi.R')
-plot.stat(stat.name = "order_continuous.est.std_dev")
-source('~/src/me/bubble_economy/plot_mi.R')
-plot.stat(stat.name = "order_continuous.est.std_dev")
-plot.stat(stat.name = "order_continuous.est.std_dev")
-source('~/src/me/bubble_economy/plot_mi.R')
-plot.stat(stat.name = "order_continuous.est.std_dev")
-source('~/src/me/bubble_economy/plot_mi.R')
-plot.stat(stat.name = "order_continuous.est.std_dev")
-plot.stat(stat.name ="susceptibility_continuous.est.mean"")
-""""""
-plot.stat(stat.name ="susceptibility_continuous.est.mean)
-""""""""
-plot.stat(stat.name ="susceptibility_continuous.est.mean)
-""""""""""""""""""""""
-plot.stat(stat.name ="susceptibility_continuous.est.mean")
-plot.stat(stat.name ="susceptibility_complete.est.mean")
-plot.stat(stat.name ="susceptibility_piecewise.est.mean")
-plot.stat(stat.name ="vel_loc_self_mi_apriori_piecewise_cochrane.mean_mi.mean")
-plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_cochrane.mean_mi.mean")
-warnings()
-source('~/src/me/bubble_economy/plot_mi.R')
-plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_cochrane.mean_mi.mean")
-plot.stat(stat.name ="vel_loc_self_mi_apriori_piecewise_cochrane.mean_mi.mean")
-plot.stat(stat.name ="vel_loc_self_mi_apriori_complete_cochrane.mean_mi.mean")
-warnings()
-source('~/src/me/bubble_economy/plot_mi.R')
-plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_cochrane.mean_mi.mean")
-warnings()
-source('~/src/me/bubble_economy/plot_mi.R')
-plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_cochrane.mean_mi.mean")

cs-36-402/.Rhistory

+array(us, dim=c(10000))
+es=array(us, dim=c(10000))
+es
+quantile(es, probs=seq(0,1,1/64))
+plot(quantile(es, probs=seq(0,1,1/64)))
+pts=seq(0,1,1/64)
+plot(quantile(es, probs=pts))
+plot(full.quantile, pts)
+full.quantile.10 = function (q) {full.quantile(q,10)}
+fix(full.quantile)
+plot(quantile(es, probs=pts))
+lines(full.quantile, pts)
+lines(full.quantile)pts), pts)
+lines(full.quantile(pts), pts)
+plot(quantile(es, probs=pts))
+plot(full.quantile, pts)
+full.quantile.10 = function (q) {full.quantile(q,10)}
+plot(full.quantile, pts)
+plot(full.quantile.10, pts)
+lines(full.quantile.10(pts), pts)
+plot(full.quantile.10, pts)
+full.quantile.10(pts)
+pts
+lines(full.quantile.10(pts), pts)
+lines(pts, full.)
+lines(pts,full.quantile.10(pts))
+plot(quantile(es, probs=pts))
+lines(pts,full.quantile.10(pts))
+plot(quantile(es, probs=pts),pts)
+plot(pts, quantile(es, probs=pts))
+lines(pts,full.quantile.10(pts))
+lines(pts,full.quantile(pts, 1))
+pts,full.quantile(pts, 10)
+full.quantile(pts, 10)
+for d in seq(1,10){lines(pts,full.quantile(pts, d))
+for (d in seq(1,10)) {lines(pts,full.quantile(pts, d))
+)
+for (d in seq(1,10)) {lines(pts,full.quantile(pts, d))}
+for (d in seq(2,10)) {lines(pts,full.quantile(pts, d))}
+for (d in seq(2,100)) {lines(pts,full.quantile(pts, d))}
+fix(full.quantile)
+fix(half.quantile)
+cats
+anova(linfit.interactey, linfit.unsexed)
+anova(linfit.interactey
+)
+anova(linfit.unsexed, linfit.interactey)
+sample(cats)
+sample(cats)
+sample(cats)
+sample(cats)
+sample(cats)
+sample(cats)
+sample(cats)
+sample(cats)
+cats[1]
+size(cats)
+length(cats)
+length(cats[1])
+length(cats[2])
+cats
+summary(cats)
+ncol(cats)
+sample.int(ncol(cats))
+sample.int(nrow(cats))
+sample.int(nrow(cats), replace=Tr)
+sample.int(nrow(cats), replace=TRUE)
+cats[,2]
+cats[2,]
+cats[[2,]]
+cats[[2]]
+cats[[,2]]
+cats[2,]
+cats[c(2,3),]
+resample.cats = function () {
+rows = sample.int(nrow(cats), replace=TRUE)
+return(cats(rows,))
+}
+resample.cats
+resample.cats()
+cats
+nrow(cats)
+resample.cats = function () {
+rows = sample.int(nrow(cats), replace=TRUE)
+}
+resample.cats()
+resample.cats = function () {
+rows = sample.int(nrow(cats), replace=TRUE)
+return(cats[rows,)]
+return(cats[rows,])
+resample.cats = function () {
+rows = sample.int(nrow(cats), replace=TRUE)
+return(cats[rows,])
+}
+resample.cats()
+resample.cats()
+resample.cats()
+resample.cats()
+resample.cats()
+summary(resample.cats())
+summary(resample.cats())
+summary(cats)
+lm(Hwt ~ Bwt * Sex, data=cats)
+lm(Hwt ~ 0+ Bwt * Sex)
+lm(Hwt ~ 0+ Bwt * Sex, data=cats)
+lm(Hwt ~ 0 + Bwt, data=newdata)
+lm(Hwt ~ 0 + Bwt, data=cats)
+coeff(lm(Hwt ~ 0 + Bwt, data=cats))
+coef(lm(Hwt ~ 0 + Bwt, data=cats))
+coef(lm(Hwt ~ 0 + Bwt, data=cats))$Bwt
+coef(lm(Hwt ~ 0 + Bwt, data=cats))
+coef(lm(Hwt ~ 0 + Bwt, data=cats))[0]
+coef(lm(Hwt ~ 0 + Bwt, data=cats))*43
+fit.cats.1 = function(newdata) { coef(lm(Hwt ~ 0 + Bwt, data=cats))}
+fit.cats.1(resample.cats())
+fit.cats.1(resample.cats())
+fit.cats.1(resample.cats())
+fit.cats.1(resample.cats())
+fit.cats.1(resample.cats())
+rep(fit.cats.1(resample.cats()), 1000)
+rep(fit.cats.1(resample.cats()), 10000)
+se(rep(fit.cats.1(resample.cats()), 10000))
+sd(rep(fit.cats.1(resample.cats()), 10000))
+replicate(fit.cats.1(resample.cats()), 10000)
+replicate(1000, fit.cats.1(resample.cats()))
+sd(replicate(1000, fit.cats.1(resample.cats())))
+hist(sample.int(nrow(cats), replace=TRUE), plot=TRUE)
+hist(sample.int(nrow(cats), replace=TRUE), plot=TRUE)
+hist(sample.int(nrow(cats), replace=TRUE), plot=TRUE)
+hist(sample.int(nrow(cats), replace=TRUE), plot=TRUE)
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+plot(full.quantile)
+plot(full.quantile,pts)
+plot(full.quantile,pts)
+plot(full.quantile(pts),pts)
+plot(full.quantile(pts, d=2),pts)
+lines(full.quantile(pts, d=2),pts)
+clf
+lines(full.quantile(pts, d=2),pts)
+plot.new
+plot.new()
+lines(full.quantile(pts, d=2),pts)
+curve(full.quantile)
+curve(full.quantile, d=1)
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+curve(full.quantile, d=1)
+curve(full.quantile)
+mypalette<-brewer.pal(7,"Greens")
+library(RColorBrewer)
+mypalette<-brewer.pal(7,"Greens")
+mypalette<-brewer.pal(9,"Greens")
+full.quantile(pts)
+apply
+()
+outer(pts, seq(2,9), full.quantile)
+outer(pts, seq(2,9,1), full.quantile)
+outer(pts, seq(2,9,by=1), full.quantile)
+outer(pts, seq(2,9), full.quantile)
+vals=data.frame(outer(pts, seq(2,9), full.quantile))
+colnames(vals) = seq(2,9)
+vals
+colnames(vals) = seq(2,10)
+dims = seq(2,10)
+outer(pts, dims, full.quantile)
+colnames(vals) = dims
+vals=data.frame(outer(pts, dims, full.quantile))
+dims = seq(2,10)
+colnames(vals) = dims
+vla
+vals
+length(dims)
+vals[,2]
+vals[,1]
+vals[,0]
+source('~/src/me/bubble_economy/quantile_plots.R')
+pts = seq(0,1,1/128)
+dims = seq(2,10)
+ndims = length(dims)
+vals=data.frame(outer(pts, dims, full.quantile))
+# get the range for the x and y axis
+xrange <- c(0,1)
+yrange <- c(-1,1)
+pts = seq(0,1,1/128)
+dims = seq(2,10)
+ndims = length(dims)
+vals=data.frame(outer(pts, dims, full.quantile))
+# get the range for the x and y axis
+xrange = c(0,1)
+yrange = c(-1,1)
+colors = brewer.pal(ndims,"Greens")
+# set up the plot
+plot(xrange, yrange, type="F", xlab="x",
+ylab="quantile" )
+line
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+pts
+vals[,1]
+vals[10]
+vals[9]
+vals$1
+vals$2
+paste(2)
+paste(c(2,2)
+)
+seq(3)
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+half.quantile = function(x,d=3) {
+g=qf(x,d-1,1)
+return(1/sqrt(g*(d-1)+1))
+}
+full_quantile = function (x, d=3) {
+x.scaled = 2*x -1
+res = sign(x.scaled)*half.quantile(1-abs(x.scaled), d)
+return(res)
+}
+pts = seq(0,1,1/128)
+dims = paste(seq(2,10))
+ndims = length(dims)
+vals=data.frame(outer(pts, dims, full.quantile))
+# get the range for the x and y axis
+xrange = c(0,1)
+yrange = c(-1,1)
+colors = brewer.pal(ndims,"Greens")
+# set up the plot
+plot(xrange, yrange, type="l", xlab="x",
+ylab="quantile")
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+display.brewer.all
+display.brewer.all ()
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+source('~/src/me/bubble_economy/quantile_plots.R')
+library(RColorBrewer)
+vs = matrix(rnorm(n=4620), nrow=10)
+us = apply(vs, 2, function(v) v/sqrt(sum(v^2)))
+es=array(us, dim=c(4620))
+points(pts, quantile)
+points(pts, quantile(es,pts))
+vs = matrix(rnorm(n=4620), nrow=3)
+us = apply(vs, 2, function(v) v/sqrt(sum(v^2)))
+es=array(us, dim=c(4620))
+points(pts, quantile(es,pts))
+source('~/src/me/cs-36-402/homework 5/q5.R')
+source('~/src/me/cs-36-402/homework 5/q5.R')
+resample.cats
+resample.cats()
+fit.cats.1(resample.cats())
+fit.cats.1(resample.cats())
+fit.cats.1(resample.cats())
+fit.cats.1(resample.cats())
+fit.cats.1(resample.cats())
+fit.cats.1(resample.cats())
+fit.cats.1(cats
+)
+rep(1000, fit.cats.1)
+rep(1000, fit.cats.1())
+rep(1000, fit.cats.1(resample.cats))
+rep(1000, fit.cats.1(resample.cats()))
+rep(fit.cats.1(resample.cats()), 1000)
+replicate(fit.cats.1(resample.cats()), 1000)
+replicate(1000,fit.cats.1(resample.cats()))
+source('~/src/me/cs-36-402/homework 5/q5.R')
+source('~/src/me/cs-36-402/homework 5/q5.R')
+cats.1.se
+cats.1.se(100)
+cats.1.se(100)
+cats.1.se(1000)
+source('~/src/me/cs-36-402/homework 5/q5.R')
+cats.1.cis(1000)
+source('~/src/me/cs-36-402/homework 5/q5.R')
+cats.1.cis(1000)
+cats.1.cis(.95, 1000)
+cats.1.cis(.05, 1000)
+anova(linfit.unsexed, linfit.interactey)
+linfit.unsexed
+summaru(linfit.unsexed)
+summary(linfit.unsexed)
+cats.1.cis(.05, 1000)
+glm(Hwt~ 0 +Bwt, data=cats)
+glm(Hwt~ 0 +Bwt+Sex, data=cats)
+glm(Hwt~ 0 +Bwt+as.numeric(Sex), data=cats)
+glm(Hwt~ 0 +Bwt+as.numeric(Sex)-1, data=cats)
+glm(Hwt~ 0 +Bwt+(as.numeric(Sex)-1), data=cats)
+cats$SexN=as.numeric(cats$Sex)-1
+cats$SexN
+glm(Hwt~ 0 +Bwt+(as.numeric(Sex)-1), data=cats)
+glm(Hwt~ 0 +Bwt+SexN, data=cats)
+glm(Hwt~ 0 +Bwt, data=cats)
+library(boot)
+cv.glm(cats,glm(Hwt~ 0 +Bwt, data=cats), K=5)
+delta.unsexed = cv.glm(cats,glm(Hwt~ 0 +Bwt, data=cats), K=5)$delta
+delta.interactey = cv.glm(cats,glm(Hwt~ 0 +Bwt+SexN, data=cats), K=5)$delta
+delta.interactey
+delta.sexed
+delta.unsexed
+source('~/src/me/bubble_economy/quantile_plots.R')
+plot.new
+plot.new()
+source('~/src/me/bubble_economy/quantile_plots.R')
+library(RColorBrewer)
+source('~/src/me/bubble_economy/quantile_plots.R')
+curve(half.quantile)
+half.4=function(x,d){half.quantile(x,4)}
+curve(half.4)
+source('~/src/me/bubble_economy/quantile_plots.R')
+curve(half.quantile)
+curve(half.4)
+source('~/src/me/bubble_economy/quantile_plots.R')
+trials = read.csv(file="Data/experiments/text/reparameterized2-1500.tsv")
+trials
+smay(tris)
+summary(trials)
+trials = read.csv(file="Data/experiments/text/reparameterized2-1500.tsv",sep='\t')
+summary(trials)
+trials$P1
+summary(trials)
+table(trails$stat_name)
+table(trials$stat_name)
+table(trials$stat_name)[0]
+summary(table(trials$stat_name))
+case.names(table(trials$stat_name))
+trial.stat.names = case.names(table(trials$stat_name))
+summary(trial.stat.names)
+names(trials)
+trials[stat_name==trial.stat.names[1]]
+trials[stat_name == trial.stat.names[1]]
+trials[stat_name == "vel_loc_self_mi_apriori_piecewise_wicks.tree_mi_raw.multiplicity"
+[54] "vel_loc_self_mi_apriori_piecewise_wicks.tree_mi_raw.std_dev"
+trials[stat_name == "vel_loc_self_mi_apriori_piecewise_wicks.tree_mi_raw.multiplicity"]
+trials$stat_name
+attach("trials")
+attach(trials)
+trials[stat_name == trial.stat.names[1]]
+trials[stat_name == trial.stat.names[1],]
+summary(trials[stat_name == trial.stat.names[1],])
+this.stat = trials[stat_name == trial.stat.names[1],]
+boxplot(count ~ spray, data = InsectSprays, col = "lightgray")
+boxplot(count ~ spray, data = InsectSprays,
+notch = TRUE, add = TRUE, col = "blue")
+range(this.stat)
+range(this.stat$stat_value)
+max(this.stat$stat_value)
+max(this.stat$P1)
+range(this.stat$P1)
+xrange=range(this.stat$P1)
+yrange = c(0, max(this.stat$stat_value))
+plot(xrange, yrange, type="n")
+table(this.stat$P2)
+size(table(this.stat$P2))
+length(table(this.stat$P2))
+colors = rainbow(length(table(this.stat$P2)))
+n.lines = length(table(this.stat$P2))
+colors = rainbow(n.lines)
+plotchar = seq(18, 18+n.lines,1)
+for (i in 1:n.lines) {}
+for (i in 1:n.lines) {
+this.line = subset(this.stat)
+}
+table(this.stat)
+table(this.stat$P1)
+table(this.stat$P2)
+summary(table(this.stat$P2))
+names(table(this.stat$P2))
+table(this.stat$P2)[0]
+table(this.stat$P2)[2]
+table(this.stat$P2)[1]
+z.vals = names(table(this.stat$P2))
+for (i in 1:n.lines) {
+this.line = subset(this.stat, this.stat$P2==zvals[i])
+lines(this.stat$P1, this.stat$stat_Value, type = b, lty=linetype[i], col=colors[i], pch=plotchar[i])
+}
+for (i in 1:n.lines) {
+this.line = subset(this.stat, this.stat$P2==z.vals[i])
+lines(this.stat$P1, this.stat$stat_Value, type = b, lty=linetype[i], col=colors[i], pch=plotchar[i])
+}
+for (i in 1:n.lines) {
+this.line = subset(this.stat, this.stat$P2==z.vals[i])
+lines(this.line$P1, this.line$stat_Value, type = "b"", lty=linetype[i], col=colors[i], pch=plotchar[i])
+}
+)
+}
+})))}}}}
+;
+)
+}
+""
+for (i in 1:n.lines) {
+this.line = subset(this.stat, this.stat$P2==z.vals[i])
+lines(this.line$P1, this.line$stat_Value, type = "b", lty=linetype[i], col=colors[i], pch=plotchar[i])
+}
+linetype
+source('~/src/me/bubble_economy/plot_mi.R')
+n.lines=1
+for (i in 1:n.lines) {
+this.line = subset(this.stat, this.stat$P2==z.vals[i])
+lines(this.line$P1, this.line$stat_Value, type = "b", lty=linetype[i], col=colors[i], pch=plotchar[i])
+}
+plot(xrange, yrange, type="n")
+for (i in 1:n.lines) {
+this.line = subset(this.stat, this.stat$P2==z.vals[i])
+lines(this.line$P1, this.line$stat_Value, type = "b", lty=linetype[i], col=colors[i], pch=plotchar[i])
+}
+this.stat
+for (i in 1:n.lines) {
+this.line = subset(this.stat, this.stat$P2==z.vals[i])
+lines(this.line$P1, this.line$stat_Value, type = "b", lty=linetype[i], col=colors[i], pch=plotchar[i])
+}subset(this.stat, this.stat$P2==z.vals[i])
+subset(this.stat, this.stat$P2==z.vals[i])
+for (i in 1:n.lines) {
+this.line = subset(this.stat, this.stat$P2==z.vals[i])
+lines(this.line$P1, this.line$stat_value, type = "b", lty=linetype[i], col=colors[i], pch=plotchar[i])
+}
+order(this.line, this.line$P2)
+order(this.line$P2, this.line$P1)
+order(this.stat$P2, this.stat$P1)
+trials[stat_name == trial.stat.names[1],][order(this.stat$P2, this.stat$P1)]
+trials[stat_name == trial.stat.names[1],][order(this.stat$P2, this.stat$P1),]
+source('~/src/me/bubble_economy/plot_mi.R')
+this.stat = trials[stat_name == trial.stat.names[1],]
+this.stat = this.stat[order(this.stat$P2, this.stat$P1),]
+this.stat = this.stat[order(this.stat$P2, this.stat$P1),]
+xrange=range(this.stat$P1)
+yrange = c(0, max(this.stat$stat_value))
+plot(xrange, yrange, type="n")
+z.vals = names(table(this.stat$P2))
+n.lines = length(z.vals)
+colors = rainbow(n.lines)
+plotchar = seq(18, 18+n.lines,1)
+linetype <- c(1:n.lines)
+i=1
+this.line = subset(this.stat, this.stat$P2==z.vals[i])[sort.order]
+this.line = subset(this.stat, this.stat$P2==z.vals[i])
+lines(this.line$P1, this.line$stat_value, type = "b", lty=linetype[i], col=colors[i], pch=plotchar[i])
+plot(xrange, yrange, type="n", xlab="P1", ylab="P2")
+source('~/src/me/bubble_economy/plot_mi.R')
+trial.stat.names[1]
+source('~/src/me/bubble_economy/plot_mi.R')
+source('~/src/me/bubble_economy/plot_mi.R')
+trial.stat.names
+plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_wicks.tree_mi_raw.mean")
+plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_wicks.tree_mi_raw.mean")
+plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_wicks.tree_mi_raw.mean")
+source('~/src/me/bubble_economy/plot_mi.R')
+plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_wicks.tree_mi_raw.mean")
+trial.stat.names[1]
+trial.stat.names
+plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_cochrane.tree_mi_raw.mean")
+plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_cochrane.tree_mi_raw.mean")
+plot.stat(stat.name ="vel_loc_self_mi_apriori_complete_cochrane.tree_mi_raw.mean")
+plot.stat(stat.name ="vel_loc_self_mi_apriori_piecewise_cochrane.tree_mi_raw.mean")
+plot.stat(stat.name ="vel_loc_self_mi_apriori_piecewise_cochrane.tree_mi_raw.mean")
+plot.stat(stat.name ="vel_loc_self_mi_apriori_piecewise_cochrane.mean_mi.mean")
+plot.stat(stat.name ="vel_loc_self_mi_apriori_piecewise_cochrane.mean_mi.mean")
+trials["P1"]
+trial.stat.names
+plot.stat(stat.name ="susceptibility_continuous.est.multiplicity"")
+""
+plot.stat(stat.name ="susceptibility_continuous.est.multiplicity")
+plot.stat(stat.name ="susceptibility_piecewise.est.multiplicity")
+trial.stat.names
+plot.stat(stat.name = "order_continuous.est.std_dev")
+source('~/src/me/bubble_economy/plot_mi.R')
+plot.stat(stat.name = "order_continuous.est.std_dev")
+source('~/src/me/bubble_economy/plot_mi.R')
+plot.stat(stat.name = "order_continuous.est.std_dev")
+source('~/src/me/bubble_economy/plot_mi.R')
+plot.stat(stat.name = "order_continuous.est.std_dev")
+source('~/src/me/bubble_economy/plot_mi.R')
+plot.stat(stat.name = "order_continuous.est.std_dev")
+plot.stat(stat.name = "order_continuous.est.std_dev")
+source('~/src/me/bubble_economy/plot_mi.R')
+plot.stat(stat.name = "order_continuous.est.std_dev")
+source('~/src/me/bubble_economy/plot_mi.R')
+plot.stat(stat.name = "order_continuous.est.std_dev")
+plot.stat(stat.name ="susceptibility_continuous.est.mean"")
+""""""
+plot.stat(stat.name ="susceptibility_continuous.est.mean)
+""""""""
+plot.stat(stat.name ="susceptibility_continuous.est.mean)
+""""""""""""""""""""""
+plot.stat(stat.name ="susceptibility_continuous.est.mean")
+plot.stat(stat.name ="susceptibility_complete.est.mean")
+plot.stat(stat.name ="susceptibility_piecewise.est.mean")
+plot.stat(stat.name ="vel_loc_self_mi_apriori_piecewise_cochrane.mean_mi.mean")
+plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_cochrane.mean_mi.mean")
+warnings()
+source('~/src/me/bubble_economy/plot_mi.R')
+plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_cochrane.mean_mi.mean")
+plot.stat(stat.name ="vel_loc_self_mi_apriori_piecewise_cochrane.mean_mi.mean")
+plot.stat(stat.name ="vel_loc_self_mi_apriori_complete_cochrane.mean_mi.mean")
+warnings()
+source('~/src/me/bubble_economy/plot_mi.R')
+plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_cochrane.mean_mi.mean")
+warnings()
+source('~/src/me/bubble_economy/plot_mi.R')
+plot.stat(stat.name ="vel_loc_self_mi_apriori_continuous_cochrane.mean_mi.mean")
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.