Getting a value out of a filename

조회 수: 2 (최근 30일)
Lucas Junghans
Lucas Junghans 2020년 6월 16일
댓글: Lucas Junghans 2020년 6월 16일
Hello everyone,
once again i have to ask you a question.
picref = imread('C:\Users\jungh\Desktop\Studienarbeit\200526_calibrationGalvo\Pictures\testdurchlauf110620(funktioniert)\PicturesDiagram\picref\testdurchlauf1106200.0000ux0.0000uy16.9537ms.png');
I am reading a picture to picref. Now i wonder if there is a command to get the value (in this case "0.0000ux") out of the filename? I want to use the values as mx x-axis in a diagram.
So if I'm reading a lot of pictures in a for loop how can i get the values? but only the ux values.
I hope you understand my question:)
Have a great day,
Lucas
  댓글 수: 2
KSSV
KSSV 2020년 6월 16일
Read about fileparts. It will ive you filename. From there use regexp. Read about it.
Lucas Junghans
Lucas Junghans 2020년 6월 16일
@ KSSV Thanks. it worked:)

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

답변 (0개)

카테고리

Help CenterFile Exchange에서 Simulink Environment Customization에 대해 자세히 알아보기

태그

제품


릴리스

R2020a

Community Treasure Hunt

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

Start Hunting!

Translated by