Returns an array indicating the variable type of each columns.
Note
The first element in the column is used to determine the type.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(csv_file), | intent(inout) | :: | me | |||
integer, | intent(out), | dimension(:), allocatable | :: | itypes | ||
logical, | intent(out) | :: | status_ok |
subroutine variable_types(me,itypes,status_ok) implicit none class(csv_file),intent(inout) :: me integer,dimension(:),allocatable,intent(out) :: itypes logical,intent(out) :: status_ok integer :: i !! counter if (allocated(me%csv_data)) then allocate(itypes(me%n_cols)) do i=1,me%n_cols call infer_variable_type(me%csv_data(1,i)%str,itypes(i)) end do status_ok = .true. else if (me%verbose) write(error_unit,'(A,1X,I5)') 'Error: class has not been initialized' status_ok = .false. end if end subroutine variable_types