3 Replies Latest reply: May 30, 2012 8:31 AM by Mark Kelly-Oracle RSS

    Regression

    920802
      Hello,

      How to make a linear regression of data column without any other describing values?
      I have only date and amount and want to make a prediction of amount.
      Dataset:
      date | sales
      2000-01-01 | 100
      2000-02-01 | 105
      ...etc.

      I put date column as date, next I tried to use it as string by to_char() transformation. Result is the same.

      Currently my ODM workflow generates error:
      Message:
      Build failed due to ORA-20025: Invalid training data for model build. .
      Detail:
      ORA-06512: przy "ODMRSYS.ODMR_ENGINE_MINING", linia 1037 ORA-06512: przy "ODMRSYS.ODMR_ENGINE_MINING", linia 3701

      When I divided this column into 2 separate: one with month number, second with year workflow could build model...
      But is it possible to work with only 1 data column for date ?


      Thanks in advance,
      Paul.

      Edited by: 917799 on 2012-05-18 03:23

      Edited by: 917799 on 2012-05-18 04:00
        • 1. Re: Regression
          Mark Kelly-Oracle
          Hi Paul,
          Date data types are not acceptable as input for building models.
          Data Miner automatically excludes them.
          So you are left with just the target column.
          You are getting the "ORA-20025: Invalid training data for model build." error due as a result of having no input columns for the model build.
          Just add a transform node prior to the build node and transform the date to a string or to a number depending on whether you want it to be treated as a categorical or numerical input.
          Thanks, Mark
          • 2. Re: Regression
            920802
            I made as you adviced.


            When I transformed data to 2 columns: year [numeric], month [numeric] regression model is processed.
            When I transformed data into 1 column: date_string [string] I have error:

            Message:
            Build failed due to ORA-20025: Invalid training data for model build. .
            Detail:
            ORA-06512: przy "ODMRSYS.ODMR_ENGINE_MINING", linia 1037 ORA-06512: przy "ODMRSYS.ODMR_ENGINE_MINING", linia 3701

            My data set is: date_string [varchar2] and value [numeric].

            It seems that one column is not enough.....
            • 3. Re: Regression
              Mark Kelly-Oracle
              Hi,
              The Build model nodes have a automatic input selection mode that will filter out columns that have poor statistics for predictive purposes.
              So in your case, if auto is on, the Build node may be removing your only input column.
              Turn off the automatic setting for the model and insure that the column is selected as input.
              Thanks, Mark