Write for loop for 24x1 struct

Hi,
I need help a writing a for loop to extract and read in a format from a field in a struct array. The struct is 24x1 and the field I want to extract from has 17 or more in it. I have:
fieldnames = dir ('fieldnamessource');
y = fieldnames.folder %% folder contains 24 files

Answers (1)

y = {fieldnames(:).folder }

2 Comments

That's helpful copying the file but hasn't answered my question.
Whats the question?

Sign in to comment.

Categories

Find more on Loops and Conditional Statements in Help Center and File Exchange

Products

Release

R2018b

Asked:

on 1 May 2019

Commented:

on 8 May 2019

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!