public static void getReport(string modelPath,double proportion=0.1,double alpha=0.05)
 {
     esriUtil.Forms.RunningProcess.frmRunningProcessDialog rp = new Forms.RunningProcess.frmRunningProcessDialog(false);
     rp.addMessage("Sample size for " + modelPath + " based on variation");
     rp.stepPGBar(50);
     rp.Show();
     dataPrepBase.modelTypes mType = ModelHelper.getModelType(modelPath);
     rp.addMessage("Model Type = " + mType.ToString());
     try
     {
         switch (mType)
         {
             case dataPrepBase.modelTypes.Accuracy:
                 fillAaReport(modelPath, rp, proportion, alpha);
                 break;
             case dataPrepBase.modelTypes.LinearRegression:
                 fillLrReport(modelPath, rp, proportion, alpha);
                 break;
             case dataPrepBase.modelTypes.MvlRegression:
                 fillMvrReport(modelPath, rp, proportion, alpha);
                 break;
             case dataPrepBase.modelTypes.LogisticRegression:
                 fillLogisticReport(modelPath, rp, proportion, alpha);
                 break;
             case dataPrepBase.modelTypes.PLR:
                 fillPlrReport(modelPath, rp, proportion, alpha);
                 break;
             case dataPrepBase.modelTypes.CovCorr:
                 fillCovCorr(modelPath, rp, proportion, alpha);
                 break;
             case dataPrepBase.modelTypes.PCA:
                 fillPcaReport(modelPath, rp, proportion, alpha);
                 break;
             case dataPrepBase.modelTypes.Cluster:
                 fillCluserReport(modelPath, rp, proportion, alpha);
                 break;
             case dataPrepBase.modelTypes.StrataCovCorr:
                 fillStrataReport(modelPath, rp, proportion, alpha);
                 break;
             default:
                 rp.addMessage("Can't estimate sample size for this type of model!");
                 break;
         }
     }
     catch (Exception e)
     {
         rp.addMessage(e.ToString());
     }
     finally
     {
         rp.stepPGBar(100);
         rp.enableClose();
     }
 }
Пример #2
0
        public static void getReport(string modelPath, double proportion = 0.1, double alpha = 0.05)
        {
            esriUtil.Forms.RunningProcess.frmRunningProcessDialog rp = new Forms.RunningProcess.frmRunningProcessDialog(false);
            rp.addMessage("Sample size for " + modelPath + " based on variation");
            rp.stepPGBar(50);
            rp.Show();
            dataPrepBase.modelTypes mType = ModelHelper.getModelType(modelPath);
            rp.addMessage("Model Type = " + mType.ToString());
            try
            {
                switch (mType)
                {
                case dataPrepBase.modelTypes.Accuracy:
                    fillAaReport(modelPath, rp, proportion, alpha);
                    break;

                case dataPrepBase.modelTypes.LinearRegression:
                    fillLrReport(modelPath, rp, proportion, alpha);
                    break;

                case dataPrepBase.modelTypes.MvlRegression:
                    fillMvrReport(modelPath, rp, proportion, alpha);
                    break;

                case dataPrepBase.modelTypes.LogisticRegression:
                    fillLogisticReport(modelPath, rp, proportion, alpha);
                    break;

                case dataPrepBase.modelTypes.PLR:
                    fillPlrReport(modelPath, rp, proportion, alpha);
                    break;

                case dataPrepBase.modelTypes.CovCorr:
                    fillCovCorr(modelPath, rp, proportion, alpha);
                    break;

                case dataPrepBase.modelTypes.PCA:
                    fillPcaReport(modelPath, rp, proportion, alpha);
                    break;

                case dataPrepBase.modelTypes.Cluster:
                    fillCluserReport(modelPath, rp, proportion, alpha);
                    break;

                case dataPrepBase.modelTypes.StrataCovCorr:
                    fillStrataReport(modelPath, rp, proportion, alpha);
                    break;

                default:
                    rp.addMessage("Can't estimate sample size for this type of model!");
                    break;
                }
            }
            catch (Exception e)
            {
                rp.addMessage(e.ToString());
            }
            finally
            {
                rp.stepPGBar(100);
                rp.enableClose();
            }
        }