<html><body><div style="color:#000; background-color:#fff; font-family:times new roman, new york, times, serif;font-size:12pt"><div><SPAN></SPAN></div>
<DIV></DIV>
<DIV style="RIGHT: auto">Sir,</DIV>
<DIV style="RIGHT: auto">I am a student in bioinformaics.I am interested to use R 2.14.1 for codon usage analysis like example given at <A style="RIGHT: auto" href="http://pbil.univ-lyon1.fr/datasets/charif04/">http://pbil.univ-lyon1.fr/datasets/charif04/</A>. Here the example is customised for three genomes.I would like to run it for my sequence data/ genome. I have filtered set of sequences having length >300bp and stored in fasta format(<VAR id=yui-ie-cursor></VAR>mygenome1.fasta) in the folder in which R2.14.1 is installed. I have edited R script as follows.But it is showing error message during running the script.Could you please check and correct it.</DIV>
<DIV style="RIGHT: auto"> </DIV>
<DIV style="RIGHT: auto"><STRONG style="RIGHT: auto"><U style="RIGHT: auto">SCRIPT</U></STRONG></DIV>
<DIV style="RIGHT: auto"> </DIV>
<DIV style="RIGHT: auto">library(ade4)<BR>library(seqinr)</DIV>
<DIV style="RIGHT: auto"><BR>sessionInfo()</DIV>
<DIV style="RIGHT: auto"> </DIV>
<DIV style="RIGHT: auto">mygenome1 <-read.fasta("mygenome1.fasta",seqonly=T) </DIV>
<DIV style="RIGHT: auto">seqmygenome1 <- lapply(mygenome1$req, getSequence)</DIV>
<DIV style="RIGHT: auto">####################################################################<BR>#<BR># From sequences, build dataframes with codon usage for each sequence. <BR>#<BR>####################################################################</DIV>
<DIV style="RIGHT: auto">mkdata <- function(seqs)<BR>{<BR> tab <- sapply(seqs, uco) <BR> tab <- as.data.frame(tab)<BR> return( tab )<BR>}</DIV>
<DIV style="RIGHT: auto">tabmygenome1 <- mkdata(seqmygenome1)</DIV>
<DIV style="RIGHT: auto">####################################################################<BR>#<BR># Run correspondence analysis on merged dataset:<BR>#<BR>####################################################################</DIV>
<DIV style="RIGHT: auto">tab <- cbind(tabmygenome1)<BR>names(tab) <- 1:ncol(tab)<BR>coa <- dudi.coa(tab, scan = FALSE, nf = 2)</DIV>
<DIV style="RIGHT: auto">####################################################################<BR>#<BR># Run synonymous codon usage analysis:<BR>#<BR>####################################################################</DIV>
<DIV style="RIGHT: auto">facaa <- as.factor(aaa(translate(sapply(rownames(tab),s2c))))<BR>scua <- wca(coa, facaa, scan = FALSE, nf = 2)</DIV>
<DIV style="RIGHT: auto">####################################################################<BR>#<BR># Plot first factorial map:<BR>#<BR>####################################################################</DIV>
<DIV style="RIGHT: auto">facsp <- as.factor(rep(c("mygenome1"),<BR> c(ncol(tabmygenome1)))<BR>s.class(scua$co, fac = facsp, cstar = 0, label = "",<BR> col = c("green"), cell=0, cpoint=0.8,<BR> sub="First factorial map for synonymous codon usage in Tri-Tryp")</DIV>
<DIV style="RIGHT: auto">s.label(scua$li, add.plot = TRUE, clab = 0.75)</DIV>
<DIV style="RIGHT: auto">legend( x = 0.1, y = -0.4, pch = 19, col = c("green"), <BR> legend = c(expression(italic("mygenome1")),<BR> <BR> xjust = 0, cex = 0.8)</DIV>
<DIV style="RIGHT: auto">####################################################################<BR>#<BR># END<BR>#<BR>####################################################################</DIV>
<DIV style="RIGHT: auto"><U style="RIGHT: auto"><STRONG style="RIGHT: auto"></STRONG></U> </DIV>
<DIV style="RIGHT: auto"><U style="RIGHT: auto"><STRONG style="RIGHT: auto">AFTER RUNNING</STRONG></U></DIV>
<DIV style="RIGHT: auto"> </DIV>
<DIV style="RIGHT: auto"> > library(ade4)</DIV>
<DIV style="RIGHT: auto">Attaching package: ‘ade4’</DIV>
<DIV style="RIGHT: auto">The following object(s) are masked from ‘package:base’:</DIV>
<DIV style="RIGHT: auto"> within</DIV>
<DIV style="RIGHT: auto">> library(seqinr)<BR>> sessionInfo()<BR>R version 2.14.1 (2011-12-22)<BR>Platform: i386-pc-mingw32/i386 (32-bit)</DIV>
<DIV style="RIGHT: auto">locale:<BR>[1] LC_COLLATE=English_United States.1252 <BR>[2] LC_CTYPE=English_United States.1252 <BR>[3] LC_MONETARY=English_United States.1252<BR>[4] LC_NUMERIC=C <BR>[5] LC_TIME=English_United States.1252 </DIV>
<DIV style="RIGHT: auto">attached base packages:<BR>[1] stats graphics grDevices utils datasets methods base </DIV>
<DIV style="RIGHT: auto">other attached packages:<BR>[1] seqinr_3.0-6 ade4_1.4-17 <BR>> mygenome1 <-read.fasta("mygenome1.fasta",seqonly=T) <BR>Error in file(con, "r") : cannot open the connection<BR>In addition: Warning message:<BR>In file(con, "r") :<BR> cannot open file 'mygenome1.fasta': No such file or directory<BR></DIV>
<DIV style="RIGHT: auto"> </DIV>
<DIV style="RIGHT: auto"> </DIV>
<DIV style="RIGHT: auto">Thanking you</DIV>
<DIV align=left>Kinshuk Chandra Nayak</DIV>
<DIV align=left>Lab. Tech & In-Charge IPR Cell</DIV>
<DIV align=left>Institute of Life Sciences</DIV>
<DIV align=left>Department of Biotechnology,Govt India</DIV>
<DIV align=left>Bhubaneswar-751023,</DIV>
<DIV align=left>India</DIV>
<DIV align=left>Ph-0674-2300137,2301460,2301476,2301219 (EXTN:279)</DIV>
<DIV align=left><B>Mail:</B> </DIV>
<DIV align=left>kinshuk@ils.res.in</DIV>
<DIV align=left><A href="mailto:kinshukils@hotmail.com" rel=nofollow target=_blank>kinshukils@hotmail.com</A></DIV>
<DIV align=left><A href="mailto:kinshuk_nayak@yahoo.co.in" rel=nofollow target=_blank>kinshuk_nayak@yahoo.co.in</A></DIV></div></body></html>