フィルターのクリア

Info

この質問は閉じられています。 編集または回答するには再度開いてください。

Data into matlab using figure

1 回表示 (過去 30 日間)
René
René 2011 年 10 月 12 日
閉鎖済み: MATLAB Answer Bot 2021 年 8 月 20 日
Hello there!
I am pretty new to Matlab and I am trying to get used to the documentation, but its pretty hard finding the information I search for on my own.
What I need to do is get data into Matlab, using the figure element via an external program. So we basically have a ton of measured data and via the application we are creating, we need to find a way, to first transform our data into the figure element of Matlab, to be able to see our data in Matlab and to be able to work with it / manipulate it.
So first, I need to know, which form the figure element actually has, to be able to do the transformation and also a way to be able to get this new figure element into Matlab. If there are some kind of tutorials on this, I would be happy to check them out!
Thanks in advance, René!
  2 件のコメント
René
René 2011 年 10 月 17 日
Ok, thanks for your help, you got me a little bit closer to a solution.
The thing is this. We basically plan on having a button in our application to start Matlab, import the data and show it in a figure in Matlab.
So what I am aksing here is this: Does the data have to be stored in a file and do I have to import the file, or is it possible to go without that?
The reason is, that we have our own internal dataformat and I think it might be faster and more performant to go without saving it in a file beforehand.
Fangjun Jiang
Fangjun Jiang 2011 年 10 月 17 日
It's likely you'll need to exchange data from your application to MATLAB through files. How hard or how easy to do the exchange depends on the format of the file. There might be some directly data exchange interface between other applications and MATLAB. But it is application dependent. What is your application? What is your data file format?

回答 (2 件)

Fangjun Jiang
Fangjun Jiang 2011 年 10 月 12 日
If you have your measured data stored in a file, such as .txt, .csv, .xls or many other format, you can use the following function to load the data into MATLAB
importdata()
uiimport()
load()
xlsread()
textread()
...
Once you have the data, you can use plot() or other functions to plot your data into a figure. For example,
x=-10:1:10;
y=rand(21,1);
plot(x,y);

Thomas
Thomas 2011 年 10 月 12 日
You can import your raw data into MATLAB. I'm not sure what you mean by "getting the data using the figure element". I assume you have the data and want to plot it as a figure using MATLAB. AS mentioned above you can use the
  • importdata()
  • load()
  • xlsread() etc..
Here are a couple of tutorials for the same:

この質問は閉じられています。

Community Treasure Hunt

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

Start Hunting!

Translated by