필터 지우기
필터 지우기

creating an input list from a large data set

조회 수: 5 (최근 30일)
Lisa Justin
Lisa Justin 2012년 10월 18일
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.

채택된 답변

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

추가 답변 (2개)

Sachin Ganjare
Sachin Ganjare 2012년 10월 18일

Azzi Abdelmalek
Azzi Abdelmalek 2012년 10월 18일
folder='C:\Lisajustin\vib\'
list=struct2cell(dir([folder '*.csv']));
Listdir=list(1,:)
  댓글 수: 2
Lisa Justin
Lisa Justin 2012년 10월 19일
편집: Lisa Justin 2012년 10월 19일
It is giving error still
Azzi Abdelmalek
Azzi Abdelmalek 2012년 10월 24일
what kind of error?

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 File Operations에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by