Talk:Wikiomics:WinterSchool day1

From OpenWetWare
Revision as of 06:02, 14 November 2013 by Darek Kedra (talk | contribs) (→‎03-4_README.excercises: new section)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

01_README.excercises

This is Readme for first set of Linux excercises.

=Task 1.2.1=
Since we can not ssh to other server outside, we have to use what we have: your vagrant virtual machine;

#change directory from your home to soft
cd ~/data/ex1

#go to home dir
cd 

cd data/ex1

#this will connect to your virtual machine as user vagrant
ssh localhost

#when asked for password, just type: vagrant
#it prints:
#Welcome to Ubuntu 12.04 LTS (GNU/Linux 3.2.0-23-generic x86_64)

#now you are logged again as vagrant, but moved automaticaly to your home directory
#Q1: how do you check it?

#to finish being logged via ssh:
exit

#
=Task 1.2.3=
#Create few files using touch command:

touch file1.txt

touch file2_long_name.dat

#list the directory content

=Task 1.2.4==
#check were you are right now in the diretory structure
pwd

#jumpt one directory above
cd ..

#explore what is at the / of the file system
cd /
ls

#jump back to the directory you have been before
cd -

#or if you are lost:
/home/vagrant/data/ex1

#there is a directory there called dir_tree
#one of the subdirectories contains file secret_file
Q: what is the secret?
 
=Task 1.2.5=
#go to /home/vagrant/data/ex1/dir_tree/work3
# jump to your /home/vagrant/data/ directory using 3 different ways (absolute, combination of ../, special sign ~)

=Task 1.2.6=
#go to /home/vagrant/data/ex1/perm_dir
# list files with permissions (ls -l) in this directory
Q1: change permissions for file6.txt. What is the first line?

Q2: there are two script files ending with sh. To execute them try:
./my_script1.sh
./my_script2.sh

What is the difference?
Q3: make my_script2.sh executable by changing permissions


+Task 1.2.7=
Q1:copy file2.txt to file2.1.txt

Q2: rename file2.1.txt to file2.1.NEW.txt

Q3: copy file6.txt to student1 directory

Q4: go to student1 directory. Link both *sh scripts so these appear as soft links in this directory
 

=Task 1.2.8=
cd /home/vagrant/data/ex1/file_content

#displays content of the file screen by screen
more myfile04.txt 

#same as above but you can scroll back
less myfile04.txt 

#displays just the first 10 top lines of the file
head myfile04.txt 

#displays the first 100 lines 
head -100 myfile04.txt 

#displays just the last 10 lines of the file
tail myfile04.txt  

#displays  the last 100 lines of the file
tail -100 myfile04.txt  

wc myfile04.txt #newline, word, and byte counts for the file

# just count the lines of the file
wc -l myfile04.txt 

=task 1.2.9=
Q1: gzip file1.gtf
Q2: go to student2 directory, untar the tar filelocated there
Q3: go to student3 directory (in ..), create gzipped tar from 3 files located there

=task 1.2.10=
cd /home/vagrant/data/ex1/checksums

Q1: there are 3 gzipped files there. Which ones are identical?

02_README.txt

=Task 1.2.11=
#goto /home/vagrant/data/ex2/pattern

#display the number of .txt files in this directory
ls *.txt | wc -l 


#we create a new file listing all the names of m*.txt files, one name per line
ls f*.txt > list_of_txt_files_starting_with_f.fof 
  

#checking what is inside
more list_of_txt_files_starting_with_f.fof

03-4_README.excercises

cd ex34
ls
# fix the fasta headers using provided python script

# reformat the fasta using fastareformat

# index the genome file for bwa

# map the genomic chicken reads using bwa

# repeat every mapping exercise for each of the mappers described on the main page

# sort and index BAM results

# view the results in IGV using your toy genome