Thread Subject: Draw cursorline on axes when mouse click on speech signal

Subject: Draw cursorline on axes when mouse click on speech signal

From: Wee Keong

Date: 28 Apr, 2009 03:21:01

Message: 1 of 3

I've created a GUI which loads and displays my speech signal in the GUI axes. Now I want to create a cursor line on the y-axis where I click and from the position that I've clicked, the program takes a 10-msec window of the speech segment immediately after the cursor line, and performs LPC analysis.

Is there a way to show cursor lines when u click somewhere and take a 10ms window of e speech segment immediately after the cursor line, and perform LPC analysis?

Subject: Draw cursorline on axes when mouse click on speech signal

From: Gavrilo Bozovic

Date: 28 Apr, 2009 06:49:04

Message: 2 of 3

"Wee Keong " <thangwk@hotmail.com> wrote in message <gt5smt$7k$1@fred.mathworks.com>...
> I've created a GUI which loads and displays my speech signal in the GUI axes. Now I want to create a cursor line on the y-axis where I click and from the position that I've clicked, the program takes a 10-msec window of the speech segment immediately after the cursor line, and performs LPC analysis.
>
> Is there a way to show cursor lines when u click somewhere and take a 10ms window of e speech segment immediately after the cursor line, and perform LPC analysis?

do something like this:

waitforbuttonpress;
xy=get(gca,'currentpoint');

xy will then contain the coordinates of the point clicked by the user. You can then draw a cursor line, and set a 10 [ms] window easily!

Subject: Draw cursorline on axes when mouse click on speech signal

From: Gautam Vallabha

Date: 29 Apr, 2009 13:20:17

Message: 3 of 3

"Wee Keong " <thangwk@hotmail.com> wrote in message <gt5smt$7k$1@fred.mathworks.com>...
> I've created a GUI which loads and displays my speech signal in the GUI axes. Now I want to create a cursor line on the y-axis where I click and from the position that I've clicked, the program takes a 10-msec window of the speech segment immediately after the cursor line, and performs LPC analysis.
>
> Is there a way to show cursor lines when u click somewhere and take a 10ms window of e speech segment immediately after the cursor line, and perform LPC analysis?

You can just plot a vertical or horizontal line, e.g. here's code to plot a vertical line
----------
[x,y]=ginput(1); % get a click
xlim = get(gca,'xlim');
ylim = get(gca,'ylim');
plot([x x], ylim); % vertical line
----------

By the way, here is a MATLAB toolbox that does almost exactly what you want (get a frame of speech, draw cursor lines, do a LPC analysis, adjust LPC filter order, etc.).
  http://www.cnbc.cmu.edu/~vallabha/lpctools/index.htm

Gautam

Tags for this Thread

Everyone's Tags:

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Tag Activity for This Thread
Tag Applied By Date/Time
speech Gautam Vallabha 29 Apr, 2009 09:15:09
lpc Gautam Vallabha 29 Apr, 2009 09:15:09
axes Wee Keong 27 Apr, 2009 23:25:04
gui Wee Keong 27 Apr, 2009 23:25:04
cursorline Wee Keong 27 Apr, 2009 23:25:04
rssFeed for this Thread

Contact us at files@mathworks.com