# Data type related debugging help

**URL:** <https://discourse.julialang.org/t/data-type-related-debugging-help/69700>\
**Category:** General Usage\
**Tags:** question\
**Created:** [October 13, 2021, 5:00pm UTC](https://discourse.julialang.org/t/data-type-related-debugging-help/69700 "2021-10-13T17:00:37Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![leon](https://avatars.discourse-cdn.com/v4/letter/l/dc4da7/32.png) [@leon](https://discourse.julialang.org/u/leon)\
**Post date:** [October 13, 2021, 5:00pm UTC](https://discourse.julialang.org/t/data-type-related-debugging-help/69700/1 "2021-10-13T17:00:37Z")

</div>

The below data (test.mat) was created inside Matlab, and the values were double inside Matlab before they were saved into the mat file. However, I’m having lots of trouble using them inside Julia:

[test.mat](https://www.icloud.com/iclouddrive/0_oWQxk7B0kBTFOEhOvBqcxIg#test)

Below is my code:

```julia
using MAT
F1 = matopen("test.mat")
x = read(F1, "x");
y = read(F1, "y");
f = read(F1, "f");
close(F1)
@info(type(x), type(y), type(f))

```

Here is the error:

```julia
**Error:** Exception while generating log record in module Main at xxx.jl:37

**│** exception =

**│** UndefVarError: type not defined

**│** Stacktrace:

**│** [1] top-level scope

**│** @ logging.jl:340

**│** [2] **include(** mod::Module, _path::String **)**

**│** @ Base ./Base.jl:386

**│** [3] **exec_options(** opts::Base.JLOptions **)**

**│** @ Base ./client.jl:285

**│** [4] **_start()**

**│** @ Base ./client.jl:485

**└** @ Main xxx.jl:37

```

Anyone knows what is the issue? Many thanks!

---

<div class="post-metadata">

**Author:** ![tim.holy](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tim.holy/32/52_2.png) [@tim.holy](https://discourse.julialang.org/u/tim.holy)\
**Post date:** [October 13, 2021, 5:14pm UTC](https://discourse.julialang.org/t/data-type-related-debugging-help/69700/2 "2021-10-13T17:14:45Z")

</div>

```julia
julia> type
ERROR: UndefVarError: type not defined

julia> typeof
typeof (built-in function)

```

---

<div class="post-metadata">

**Author:** ![leon](https://avatars.discourse-cdn.com/v4/letter/l/dc4da7/32.png) [@leon](https://discourse.julialang.org/u/leon)\
**Post date:** [October 13, 2021, 5:37pm UTC](https://discourse.julialang.org/t/data-type-related-debugging-help/69700/3 "2021-10-13T17:37:37Z")

</div>

Many thanks. Now I’m able to get the below:

**Info:** Matrix{Float64}  
**│** typeof(y) = Matrix{Float64} (alias for Array{Float64, 2})  
**└** typeof(f) = Matrix{Float64} (alias for Array{Float64, 2})

It seems that my 1-column data is now considered a two column array within Julia? How should I fix this issue? Each of my x, y, and f should be one-column 'double" data.

Thanks.
