comparison barplot.R @ 16:fe749b5b462e draft default tip

Uploaded
author mb2013
date Wed, 20 Nov 2013 07:20:16 -0500
parents
children
comparison
equal deleted inserted replaced
15:0cef5c0382c8 16:fe749b5b462e
1 #Plottool makes a graph barplot of variance
2 #developer: M.Baak
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()