creating an input list from a large data set

4 views (last 30 days)
Hi! I want to create an input list from a large data set. dir .*csv displays all the csv but when i do
dir='C:\Lisajustin\vib'
Listdir=sprintf('%s%s',dir, ' *.csv');
i get error
Error using ==> sprintf
Function is not defined for 'struct' inputs.

Accepted Answer

RNTL
RNTL on 24 Oct 2012
why don't you simply write
clear dir;
list = dir('c:\Lisajustin\vib\*.csv');

More Answers (2)

Sachin Ganjare
Sachin Ganjare on 18 Oct 2012

Azzi Abdelmalek
Azzi Abdelmalek on 18 Oct 2012
folder='C:\Lisajustin\vib\'
list=struct2cell(dir([folder '*.csv']));
Listdir=list(1,:)

Categories

Find more on File Operations in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!