comparison variance_plot.R @ 19:f3d9bb18110a draft default tip

Uploaded
author mb2013
date Tue, 20 May 2014 03:30:07 -0400
parents
children
comparison
equal deleted inserted replaced
18:a207e838f232 19:f3d9bb18110a
1 #Plottool makes a graph barplot of the variance
2 #MB
3
4 #commands extracting of commandline
5 args <- commandArgs(TRUE)
6
7 #input files and options
8 input <- args[1]
9 title <- args[2]
10 #output file
11 output <- args[3]
12
13 #reading of input files
14 read <- read.csv(file <- input,header = TRUE)
15
16 stdev<- read[,1] #standard deviation
17 pov = stdev^2/sum(stdev^2) #variance
18
19 png(output) #output in png format
20
21
22 #creating the barplot with the variance of pca
23 suppressMessages(barplot(pov, main = title, names.arg = c(1:NROW(pov)), ylim = c(0,1), col = heat.colors(3)))
24
25
26 graphics.off()