df_log_column Subroutine

public subroutine df_log_column(df, col_index)

Apply natural logarithm to column

@param[in,out] df The data frame instance @param[in] col_index Index of the column

Warning

Values must be positive

Arguments

Type IntentOptional Attributes Name
type(data_frame), intent(inout) :: df
integer, intent(in) :: col_index

Source Code

    subroutine df_log_column(df, col_index)
        type(data_frame), intent(inout) :: df
        integer, intent(in) :: col_index

        real(rk), dimension(:), allocatable :: col

        col = df_get_col_real(df, col_index)
        col = log(col)
        call df_set_col_real(df, col_index, col)
    end subroutine df_log_column