Sumários
Session 4
21 Setembro 2022, 10:30 • Nuno Miguel Brites
5 Writing data to files 29
5.1 Writing data to a text file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
5.2 Variants of write.table() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
5.3 Basic writing functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
5.4 Working with binary files: using save() and load() .
Session 3
19 Setembro 2022, 09:30 • Nuno Miguel Brites
3.5 Lists . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
4 Reading in data 25
4.1 Reading data from user input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
4.2 The R working directory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
4.3 Reading data from a text file (*.dat) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
4.4 Variants of read.table() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
4.5 Reading text files from Excel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
Session 2
14 Setembro 2022, 10:30 • Nuno Miguel Brites
3 Data structures 9
3.1 Vector . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
3.2 Factor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
3.3 Matrix and array . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11