Difference between revisions of "Useful tools"
(→How to use matlab from home) |
(→With windows) |
||
(21 intermediate revisions by 5 users not shown) | |||
Line 1: | Line 1: | ||
+ | Some tips how to get matlab working for students of the [[Course: "Solving Biological Problems that require Math"]] | ||
+ | |||
+ | == R resources == | ||
+ | |||
+ | There are many good R tutorials online (google "R tutorial"). However, many of them are hard to follow for beginners with no background in statistics and programming. Here is one R tutorial that we recommend because it's very basic and interactive with a console where you have to type in the correct commands before you can move on: | ||
+ | |||
+ | [http://tryr.codeschool.com http://tryr.codeschool.com] | ||
+ | |||
+ | The tutorial covers the following topics (this is all very basic, you have to know these things if you want to use R for your work): | ||
+ | |||
+ | '''1. Introduction to R''' | ||
+ | * Expressions | ||
+ | * Logical Values | ||
+ | * Variables | ||
+ | * Functions | ||
+ | * Help | ||
+ | * Files | ||
+ | |||
+ | '''2. Vectors''' | ||
+ | * Vectors | ||
+ | * Sequence Vectors | ||
+ | * Vector Access | ||
+ | * Vector Names | ||
+ | * Plotting One Vector | ||
+ | * Vector Math | ||
+ | * Scatter Plots | ||
+ | * NA Values | ||
+ | |||
+ | '''3. Matrices''' | ||
+ | * Matrices | ||
+ | * Matrix Access | ||
+ | * Matrix Plotting | ||
+ | |||
+ | '''4. Summary Statistics''' | ||
+ | * Mean | ||
+ | * Median | ||
+ | * Standard Deviation | ||
+ | |||
+ | '''5. Factors''' | ||
+ | * Creating Factors | ||
+ | * Plots With Factors | ||
+ | |||
+ | '''6. Data frames''' | ||
+ | * Data Frames | ||
+ | * Data Frame Access | ||
+ | * Loading Data Frames | ||
+ | * Merging Data Frames | ||
+ | |||
+ | '''7. Real-world data''' | ||
+ | * Some Real World Data | ||
+ | * ggplot2 | ||
+ | |||
== How to use matlab from home == | == How to use matlab from home == | ||
− | + | === With windows === | |
− | + | * Installez [https://sourceforge.net/projects/xming XMing] avec la configuration proposée par défaut. | |
+ | * Téléchargez [http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html Putty] | ||
+ | * Connectez-vous au réseau sécurisé de l'unil (https://reseau.unil.ch) | ||
+ | * Lancez Xming, puis lancez Putty. Configurez une nouvelle session dans Putty avec les paramètres suivants: | ||
+ | ** Session > Host name : server.unil.ch ("server" is given to you by the assistant) | ||
+ | ** Connection > SSH > X11 : cliquez sur "Enable X11 forwarding" | ||
+ | ** Session > Saved Sessions : donnez un nom à votre session (p.ex gertrud), puis cliquez sur save. Comme ça, les prochaines fois, vous n'aurez qu'à faire "Load gertrud". | ||
+ | ** Ne modifiez pas d'autres paramètres dans Putty. | ||
+ | ** Au bas de la fenêtre, cliquez sur Open. Un terminal s'ouvre, en vous demandant votre username, puis votre password. Ensuite, vous êtes connecté au serveur. | ||
+ | ** Pour lancer matlab, tapez dans le terminal : matlab & | ||
− | + | === With Mac or Linux === | |
+ | Log in the unil network (https://reseau.unil.ch). | ||
+ | Then just use open a terminal use the following command: | ||
− | + | $ ssh username@server.unil.ch -Y | |
+ | where username is the username that was given to you by your assistant and server is the name of the server (also given by your assistant). | ||
== How copy files from your windows computer to gertrud (and vice-versa) == | == How copy files from your windows computer to gertrud (and vice-versa) == | ||
− | You can can install winscp. | + | === From Windows === |
+ | |||
+ | You can can install [http://winscp.net/download/winscp418.exe winscp] and use that program. | ||
+ | |||
+ | |||
+ | === From linux or Mac === | ||
+ | |||
+ | Open a terminal and use the follwing command | ||
+ | |||
+ | $ scp filename username@gertrud.unil.ch:./mydir | ||
+ | |||
+ | where username is your username and mydir is the name of the existing repository on gertrud where you want to put the file. | ||
+ | Use the -R option to copy a whole directory. | ||
+ | |||
+ | Vice versa: | ||
+ | |||
+ | $ scp username@gertrud.unil.ch:./mydir/filename my_local_dir/ | ||
+ | |||
+ | where my_local_dir is the name of the existing local repository where you want to put the file. | ||
== Quelques commandes linux utiles == | == Quelques commandes linux utiles == |
Latest revision as of 16:49, 3 June 2016
Some tips how to get matlab working for students of the Course: "Solving Biological Problems that require Math"
Contents
R resources
There are many good R tutorials online (google "R tutorial"). However, many of them are hard to follow for beginners with no background in statistics and programming. Here is one R tutorial that we recommend because it's very basic and interactive with a console where you have to type in the correct commands before you can move on:
The tutorial covers the following topics (this is all very basic, you have to know these things if you want to use R for your work):
1. Introduction to R
- Expressions
- Logical Values
- Variables
- Functions
- Help
- Files
2. Vectors
- Vectors
- Sequence Vectors
- Vector Access
- Vector Names
- Plotting One Vector
- Vector Math
- Scatter Plots
- NA Values
3. Matrices
- Matrices
- Matrix Access
- Matrix Plotting
4. Summary Statistics
- Mean
- Median
- Standard Deviation
5. Factors
- Creating Factors
- Plots With Factors
6. Data frames
- Data Frames
- Data Frame Access
- Loading Data Frames
- Merging Data Frames
7. Real-world data
- Some Real World Data
- ggplot2
How to use matlab from home
With windows
- Installez XMing avec la configuration proposée par défaut.
- Téléchargez Putty
- Connectez-vous au réseau sécurisé de l'unil (https://reseau.unil.ch)
- Lancez Xming, puis lancez Putty. Configurez une nouvelle session dans Putty avec les paramètres suivants:
- Session > Host name : server.unil.ch ("server" is given to you by the assistant)
- Connection > SSH > X11 : cliquez sur "Enable X11 forwarding"
- Session > Saved Sessions : donnez un nom à votre session (p.ex gertrud), puis cliquez sur save. Comme ça, les prochaines fois, vous n'aurez qu'à faire "Load gertrud".
- Ne modifiez pas d'autres paramètres dans Putty.
- Au bas de la fenêtre, cliquez sur Open. Un terminal s'ouvre, en vous demandant votre username, puis votre password. Ensuite, vous êtes connecté au serveur.
- Pour lancer matlab, tapez dans le terminal : matlab &
With Mac or Linux
Log in the unil network (https://reseau.unil.ch). Then just use open a terminal use the following command:
$ ssh username@server.unil.ch -Y
where username is the username that was given to you by your assistant and server is the name of the server (also given by your assistant).
How copy files from your windows computer to gertrud (and vice-versa)
From Windows
You can can install winscp and use that program.
From linux or Mac
Open a terminal and use the follwing command
$ scp filename username@gertrud.unil.ch:./mydir
where username is your username and mydir is the name of the existing repository on gertrud where you want to put the file. Use the -R option to copy a whole directory.
Vice versa:
$ scp username@gertrud.unil.ch:./mydir/filename my_local_dir/
where my_local_dir is the name of the existing local repository where you want to put the file.
Quelques commandes linux utiles
Sous linux comme sous windows, les fichiers sont organisée selon une hierarchie. Le sommet (ou la racine) de cette hierarchie est le fichier ~username où username et votre username. Il est préférable de ne pas mettre d'espace dans vos noms de fichiers et de répertoires.
- changer le mot de passe:
$ passwd
- créer un répertoire:
$ mkdir nom_rep
où "nom_rep" est le nom du répertoire
- effacer un ficher:
$ rm nom_fichier
où "nom_fichier" est le nom du fichier à effacer
- renommer un ficher:
$ mv ancien_nom nouveau_nom
où "ancien_nom" est le nom du fichier à renommer "nouveau_nom" et le nom à donner
- lister le contenu du répertoire courant:
$ ls
- lister le contenu d'un sous-répertoire du répertoire courant:
$ ls sous_rep
où "sous_rep" est le nom du sous-répertoire
- se déplacer dans un sous-répertoire du répertoire courant:
$ cd sous_rep
où "sous_rep" est le nom su sous-répertoire
- se déplacer dans un sur-répertoire du répertoire courant (monter dans la hiérarchie des répertoire):
$ cd ..
- aller au sommet de sa hierarchie
$ cd
- voir dans quel répertoire on se trouve:
$ pwd