我正致力于判别分析,并希望使用MATLAB对一些数据进行分类.在MATLAB中给出的Fisher's Iris Data示例中(详情请访问www.mathworks.com/products/demos/statistics/classdemo.html),他们只考虑前2个变量(Sepal Length&Width).我想继续进行具有更多功能的分类,如花瓣长度和花瓣宽度.
此外,MATLAB函数gscatter似乎只需要2个变量.
gscatter(meas(:,1), meas(:,2), species,'rgb','osd');
我想包括meas(:,3)并继续.请帮助我.谢谢
我试图根据当前场景的索引读取不同的文本文件(在Unity术语中).所以,我决定使用如下的switch语句:
void MyReadString()
{
Scene currentScene = SceneManager.GetActiveScene(); // Unity command to get the current scene info
int buildIndex = currentScene.buildIndex; // Unity command to get the current scene number
string path = string.Empty; // Create an empty string variable to hold the path information of text files
switch (buildIndex)
{
case 0:
string path = "Assets/Scripts/some.txt"; //It says here that the variable path is assigned but never used!
break;
case 1:
string path = "Assets/Scripts/another.txt"; //Same here - assigned …Run Code Online (Sandbox Code Playgroud)