weka.core.Utils.replaceMissingWithMAX_VALUE()方法的使用及代码示例

x33g5p2x  于2022-02-01 转载在 其他  
字(2.0k)|赞(0)|评价(0)|浏览(80)

本文整理了Java中weka.core.Utils.replaceMissingWithMAX_VALUE()方法的一些代码示例,展示了Utils.replaceMissingWithMAX_VALUE()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Utils.replaceMissingWithMAX_VALUE()方法的具体详情如下:
包路径:weka.core.Utils
类名称:Utils
方法名:replaceMissingWithMAX_VALUE

Utils.replaceMissingWithMAX_VALUE介绍

[英]Replaces all "missing values" in the given array of double values with MAX_VALUE.
[中]用MAX_值替换给定双值数组中的所有“缺失值”。

代码示例

代码示例来源:origin: Waikato/weka-trunk

/**
 * Sorts a given array of doubles in ascending order and returns an array of
 * integers with the positions of the elements of the original array in the
 * sorted array. NOTE THESE CHANGES: the sort is no longer stable and it
 * doesn't use safe floating-point comparisons anymore. Occurrences of
 * Double.NaN are treated as Double.MAX_VALUE.
 * 
 * @param array this array is not changed by the method!
 * @return an array of integers with the positions in the sorted array.
 */
public static/* @pure@ */int[] sort(/* @non_null@ */double[] array) {
 int[] index = initialIndex(array.length);
 if (array.length > 1) {
  array = array.clone();
  replaceMissingWithMAX_VALUE(array);
  quickSort(array, index, 0, array.length - 1);
 }
 return index;
}

代码示例来源:origin: nz.ac.waikato.cms.weka/weka-stable

/**
 * Sorts a given array of doubles in ascending order and returns an array of
 * integers with the positions of the elements of the original array in the
 * sorted array. NOTE THESE CHANGES: the sort is no longer stable and it
 * doesn't use safe floating-point comparisons anymore. Occurrences of
 * Double.NaN are treated as Double.MAX_VALUE.
 * 
 * @param array this array is not changed by the method!
 * @return an array of integers with the positions in the sorted array.
 */
public static/* @pure@ */int[] sort(/* @non_null@ */double[] array) {
 int[] index = initialIndex(array.length);
 if (array.length > 1) {
  array = array.clone();
  replaceMissingWithMAX_VALUE(array);
  quickSort(array, index, 0, array.length - 1);
 }
 return index;
}

代码示例来源:origin: Waikato/weka-trunk

replaceMissingWithMAX_VALUE(array);
quickSort(array, index, 0, array.length - 1);

代码示例来源:origin: nz.ac.waikato.cms.weka/weka-stable

replaceMissingWithMAX_VALUE(array);
quickSort(array, index, 0, array.length - 1);

相关文章

微信公众号

最新文章

更多