Click here to Skip to main content
13,288,520 members (68,718 online)
Rate this:
Please Sign up or sign in to vote.
See more:
Dear all,
I have question about importing data in my program. I do not know how can import name of txt file(that include data) in my program and use this file as argument of my function in Matlab. In fact, I want, user of my program can input name of txt file; after that one of my function in my program usese this file as input argument of function. I want something like load.
Posted 28-Jan-13 3:20am
Rate this: bad
Please Sign up or sign in to vote.

Solution 1

Get the name of the file from the user, either by console or common dialog. Then you just need to read the contents of the file and process it as required.
Rate this: bad
Please Sign up or sign in to vote.

Solution 2

The best way for doing this is that we use a strcat function that exists in Matlab.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy |
Web04 | 2.8.171207.1 | Last Updated 30 Jan 2013
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100