How can i create a term document matrix?

I have a directory containing 141 files and i need to make a term document matrix. Can anyone help me please? thanks in advance
this is my inital code to get the files
dirinformation = dir('*.txt'); filenames = {dirinformation.name}; data = cell(numel(filenames),2); data(:,1) = regexprep(fileNames, '.txt','');
for i = 1:length(fileNames) fid = fopen(char(fileNames{i})); data{ii,2} = textscan(fid,'%s','delimiter', '. ; , * : /'); end

댓글 수: 1

Stephen23
Stephen23 2015년 3월 11일
Please edit your code to be more readable by editing the question and using the {} Code button that you will find above the textbox.

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

답변 (0개)

카테고리

도움말 센터File Exchange에서 Standard File Formats에 대해 자세히 알아보기

태그

질문:

2015년 3월 11일

댓글:

2015년 3월 11일

Community Treasure Hunt

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

Start Hunting!

Translated by