How to do I get the standard deviation from an eeg input signal in SImulink?
Hello I’m trying to make a function block that calculates standard deviation of the signal, as the standard deviation blocks do not give me the standard deviation of the SIMULINK signal (they either give me 0 or say it needs discrete values). However that doesnt work either, is there a way for me to get the standard deviationl? I want to equal the signal to 0 if the sdv is higher than a certain value.
I’ve tried the following but it isn’t working.
function y = fcn(u)
std(u)
y = std(u)
end
my input is an eeg signal taken from the workspace using "from workspace" (simin)Hello I’m trying to make a function block that calculates standard deviation of the signal, as the standard deviation blocks do not give me the standard deviation of the SIMULINK signal (they either give me 0 or say it needs discrete values). However that doesnt work either, is there a way for me to get the standard deviationl? I want to equal the signal to 0 if the sdv is higher than a certain value.
I’ve tried the following but it isn’t working.
function y = fcn(u)
std(u)
y = std(u)
end
my input is an eeg signal taken from the workspace using "from workspace" (simin) Hello I’m trying to make a function block that calculates standard deviation of the signal, as the standard deviation blocks do not give me the standard deviation of the SIMULINK signal (they either give me 0 or say it needs discrete values). However that doesnt work either, is there a way for me to get the standard deviationl? I want to equal the signal to 0 if the sdv is higher than a certain value.
I’ve tried the following but it isn’t working.
function y = fcn(u)
std(u)
y = std(u)
end
my input is an eeg signal taken from the workspace using "from workspace" (simin) simulink, signal processing MATLAB Answers — New Questions