We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5a0c9ca commit 4ffc3abCopy full SHA for 4ffc3ab
files/test.csv
@@ -0,0 +1,20 @@
1
+id,first_name,age,ok
2
+1,Julie,80.244,false
3
+2,Jose,11.569,true
4
+3,Lois,12.339,true
5
+4,Walter,63.173,false
6
+5,Timothy,57.063,true
7
+6,Barbara,79.705,true
8
+7,Douglas,19.347,false
9
+8,Tina,16.909,true
10
+9,Gregory,67.749,true
11
+10,Larry,43.705,true
12
+11,Tina,9.931,true
13
+12,Kelly,72.657,true
14
+13,Marilyn,10.901,true
15
+14,Gregory,9.966,true
16
+15,Earl,10.875,true
17
+16,Evelyn,33.268,true
18
+17,Carol,54.498,false
19
+18,Alice,2.505,true
20
+19,Randy,39.775,false
src/tests/csv_test.f90
@@ -24,7 +24,7 @@ program csv_test
24
integer,dimension(:),allocatable :: itypes
25
26
! read the file:
27
- call f%read('test.csv',header_row=1,status_ok=status_ok)
+ call f%read('../files/test.csv',header_row=1,status_ok=status_ok)
28
29
! print the header and type info:
30
call f%get_header(header,status_ok)
@@ -44,21 +44,13 @@ program csv_test
44
end do
45
46
write(*,*) ''
47
- write(*,*) 'get the position vectors:'
+ write(*,*) 'get some vectors:'
48
49
50
- write(*,*) 'x:'
51
- call f%get(2,x,status_ok)
+ write(*,*) 'age:'
+ call f%get(3,x,status_ok)
52
write(*,'(F27.16,1x)',advance='NO') x
53
54
- write(*,*) 'y:'
55
- call f%get(3,y,status_ok)
56
- write(*,'(F27.16,1x)',advance='NO') y
57
- write(*,*) ''
58
- write(*,*) 'z:'
59
- call f%get(4,z,status_ok)
60
- write(*,'(F27.16,1x)',advance='NO') z
61
62
63
! now test creating a CSV:
64
call f2%open('test2.csv',n_cols=4,status_ok=status_ok)
0 commit comments