Difference between revisions of "Error Messages/41095"

 
(4 intermediate revisions by 3 users not shown)
Line 1: Line 1:
= Error Message Examples =
+
[[Category: Error messages]]
  
  The value 2016 given in the <<map>> parameter to [[Aggregate]] at IndexI=1-Jun-2015
+
== Error message examples ==
  is not an element of the Years, the <<targetIndex>>. The elements of <<man>> must be
+
 
 +
<pre style="background:white; border:white; margin-left: 1em; font-style:italic">
 +
  The value 2016 given in the «map» parameter to Aggregate at IndexI=1-Jun-2015
 +
  is not an element of the Years, the «targetIndex». The elements of «map» must be
 
  elements of Years, or they may be null.
 
  elements of Years, or they may be null.
  
= Cause =
+
In Function Aggregate(«x», «map», i: IndexI, targetIndex: Years), the value in the
 +
«map» parameter at index IndexI = 1-Jan-2015 is not an element of the target index Years.
 +
Each value of «map» should be either an element of the index Years, or the value Null.
 +
</pre>
 +
 
 +
== Cause ==
 +
 
 +
The «map» parameter to [[Aggregate]] function should contain a value of the «targetIndex» for each value of the index «i» of the parameter «x». For the specified value of «i», «map» contains a value not in the «targetIndex».
 +
 
 +
If «Positional» is set to true, «map» should contain integers specifying positional values in «targetIndex» -- i.e. numbers between 1 and Size(''targetIndex'').
  
The <<map>> parameter to [[Aggregate]] must be indexed by the << i >> parameter and must hold values present in the <<targetIndex>> if the <<positional>> parameter is not set to true. If the <<positional>> parameter is specified to be true, the <<map>> parameter to the function must be numeric and a positional index along the <<targetIndex>> parameter index. You have not set the <<positional>> parameter to be true, and at least one cell in the passed in <<map>> parameter contains a value not present in <<targetIndex>>.
+
== Remedies ==
  
Please click on the following link to see [[Aggregate#Examples|an example use of Aggregate]].
+
Correct the «map» parameter so that all the cells hold a value that is present in the «targetIndex» parameter.  
  
= Remedies =
+
If Map intentionally includes values that aren't in «targetIndex», then you can
 +
* (in [[Analytica 5.0]] or later) add the optional <code>noMapError:true</code> parameter, e.g., like this:
 +
::<code>[[Aggregate]]( X, Map, I, J, noMapError:true )</code>
 +
* Or you can change Map to [[Null]] for elements not in the target index.
 +
::<code>[[Aggregate]]( X, If @[J=Map] then Map Else Null, I, J )</code>
  
Correct the <<map>> parameter so that all the cells hold a value that is present in the <<targetIndex>> parameter.
 
  
<br><comments />
+
==See Also==
 +
* [[Aggregate]]
 +
* [[Function calls and parameters]]
 +
* [[Objects and Values]]

Latest revision as of 18:38, 29 June 2017


Error message examples

 The value 2016 given in the «map» parameter to Aggregate at IndexI=1-Jun-2015
 is not an element of the Years, the «targetIndex». The elements of «map» must be
 elements of Years, or they may be null.

 In Function Aggregate(«x», «map», i: IndexI, targetIndex: Years), the value in the 
 «map» parameter at index IndexI = 1-Jan-2015 is not an element of the target index Years.
 Each value of «map» should be either an element of the index Years, or the value Null.

Cause

The «map» parameter to Aggregate function should contain a value of the «targetIndex» for each value of the index «i» of the parameter «x». For the specified value of «i», «map» contains a value not in the «targetIndex».

If «Positional» is set to true, «map» should contain integers specifying positional values in «targetIndex» -- i.e. numbers between 1 and Size(targetIndex).

Remedies

Correct the «map» parameter so that all the cells hold a value that is present in the «targetIndex» parameter.

If Map intentionally includes values that aren't in «targetIndex», then you can

  • (in Analytica 5.0 or later) add the optional noMapError:true parameter, e.g., like this:
Aggregate( X, Map, I, J, noMapError:true )
  • Or you can change Map to Null for elements not in the target index.
Aggregate( X, If @[J=Map] then Map Else Null, I, J )


See Also

Comments


You are not allowed to post comments.