@@ -93,7 +93,7 @@ angular
93
93
94
94
/**
95
95
* @ngdoc service
96
- * @name predicsis.jsSDK.models.Datafile
96
+ * @name predicsis.jsSDK.models.Datafiles
97
97
* @requires $q
98
98
* @requires Restangular
99
99
* @description
@@ -111,7 +111,7 @@ angular
111
111
* </tr>
112
112
* <tr>
113
113
* <td><span class="badge get">get</span> <kbd>/data_files/:id/signed_url</kbd></td>
114
- * <td><kbd>{@link predicsis.jsSDK.models.Datafiles#methods_get_signed_url Datafiles.getSignedUrl()}</kbd></td>
114
+ * <td><kbd>{@link predicsis.jsSDK.models.Datafiles#methods_getsignedurl Datafiles.getSignedUrl()}</kbd></td>
115
115
* <td></td>
116
116
* </tr>
117
117
* <tr>
@@ -2610,6 +2610,19 @@ angular
2610
2610
} ) ;
2611
2611
}
2612
2612
2613
+ function createUnivariateSupervisedReport ( project ) {
2614
+ var Datasets = $injector . get ( 'Datasets' ) ;
2615
+ return Datasets . getChildren ( project . learning_dataset_id , project . dictionary_id )
2616
+ . then ( function ( children ) {
2617
+ return self . create ( {
2618
+ type : 'univariate_supervised' ,
2619
+ dataset_id : children . train . id ,
2620
+ dictionary_id : project . dictionary_id ,
2621
+ variable_id : project . target_variable_id
2622
+ } ) ;
2623
+ } ) ;
2624
+ }
2625
+
2613
2626
// -----------------------------------------------------------------------------------------------------------------
2614
2627
2615
2628
/**
@@ -2680,12 +2693,7 @@ angular
2680
2693
* @return {Object } Promise of a report
2681
2694
*/
2682
2695
this . createUnivariateSupervisedReport = function ( project ) {
2683
- return self . create ( {
2684
- type : 'univariate_supervised' ,
2685
- dataset_id : project . learning_dataset_id ,
2686
- dictionary_id : project . dictionary_id ,
2687
- variable_id : project . target_variable_id
2688
- } ) ;
2696
+ return createUnivariateSupervisedReport ( project ) ;
2689
2697
} ;
2690
2698
2691
2699
/**
0 commit comments