title: Accessing data in a nested structure
body: <p>Okay so I've found a better way of accessing my files but I'm still a bit stuck. </p>
  
  <p>My code so far:</p>
  
  <pre><code>clc % clear window
  clear %clear workspace
  
  numfiles = 21;
  data = cell(1, numfiles);
  
  obsdata = dir('*.mat'); 
  numfiles = length(obsdata);
  data = cell(1, numfiles);
  
  for k = 1:numfiles 
    data{k} = load(obsdata(k).name); 
  end
  </code></pre>
  
  <p>This sorts my data out.
  There are 21 cells that contains the J6 - files as shown (the list of the files can be seen on the left):
  <img src="https://i.stack.imgur.com/MpcDl.png" alt="Files">
  Clicking each cell brings me to a structure:
  <img src="https://i.stack.imgur.com/3v1UP.png" alt="Structure">
  Each of which contains data that I want to access.</p>
  
  <p>I'm unsure as to how to go about writing my code so that I can store the data in the last part into two arrays (wavelength and intensity)</p>