DEVELOPMENT... { "data_id": "44643", "name": "kr-vs-kp_seed_0_nrows_2000_nclasses_10_ncols_100_stratify_True", "exact_name": "kr-vs-kp_seed_0_nrows_2000_nclasses_10_ncols_100_stratify_True", "version": 1, "version_label": "bce1d8cd-775d-4cd3-8d1c-80b856b6ba93", "description": "Subsampling of the dataset kr-vs-kp (3) with\n\nseed=0\nargs.nrows=2000\nargs.ncols=100\nargs.nclasses=10\nargs.no_stratify=True\nGenerated with the following source code:\n\n\n```python\n def subsample(\n self,\n seed: int,\n nrows_max: int = 2_000,\n ncols_max: int = 100,\n nclasses_max: int = 10,\n stratified: bool = True,\n ) -> Dataset:\n rng = np.random.default_rng(seed)\n\n x = self.x\n y = self.y\n\n # Uniformly sample\n classes = y.unique()\n if len(classes) > nclasses_max:\n vcs = y.value_counts()\n selected_classes = rng.choice(\n classes,\n size=nclasses_max,\n replace=False,\n p=vcs \/ sum(vcs),\n )\n\n # Select the indices where one of these classes is present\n idxs = y.index[y.isin(classes)]\n x = x.iloc[idxs]\n y = y.iloc[idxs]\n\n # Uniformly sample columns if required\n if len(x.columns) > ncols_max:\n columns_idxs = rng.choice(\n list(range(len(x.columns))), size=ncols_max, replace=False\n )\n sorted_column_idxs = sorted(columns_idxs)\n selected_columns = list(x.columns[sorted_column_idxs])\n x = x[selected_columns]\n else:\n sorted_column_idxs = list(range(len(x.columns)))\n\n if len(x) > nrows_max:\n # Stratify accordingly\n target_name = y.name\n data = pd.concat((x, y), axis=\"columns\")\n _, subset = train_test_split(\n data,\n test_size=nrows_max,\n stratify=data[target_name],\n shuffle=True,\n random_state=seed,\n )\n x = subset.drop(target_name, axis=\"columns\")\n y = subset[target_name]\n\n # We need to convert categorical columns to string for openml\n categorical_mask = [self.categorical_mask[i] for i in sorted_column_idxs]\n columns = list(x.columns)\n\n return Dataset(\n # Technically this is not the same but it's where it was derived from\n dataset=self.dataset,\n x=x,\n y=y,\n categorical_mask=categorical_mask,\n columns=columns,\n )\n```", "format": "arff", "uploader": "David Wilson", "uploader_id": 32840, "visibility": "public", "creator": "\"Eddie Bergman\"", "contributor": null, "date": "2022-11-17 18:39:31", "update_comment": null, "last_update": "2022-11-17 18:39:31", "licence": "Public", "status": "active", "error_message": null, "url": "https:\/\/api.openml.org\/data\/download\/22111405\/dataset", "default_target_attribute": "class", "row_id_attribute": null, "ignore_attribute": null, "runs": 0, "suggest": { "input": [ "kr-vs-kp_seed_0_nrows_2000_nclasses_10_ncols_100_stratify_True", "Subsampling of the dataset kr-vs-kp (3) with seed=0 args.nrows=2000 args.ncols=100 args.nclasses=10 args.no_stratify=True Generated with the following source code: ```python def subsample( self, seed: int, nrows_max: int = 2_000, ncols_max: int = 100, nclasses_max: int = 10, stratified: bool = True, ) -> Dataset: rng = np.random.default_rng(seed) x = self.x y = self.y # Uniformly sample classes = y.unique() if len(classes) > nclasses_max: vcs = y.value_counts() selected_classes = rng.choice( cla " ], "weight": 5 }, "qualities": { "NumberOfInstances": 2000, "NumberOfFeatures": 37, "NumberOfClasses": 2, "NumberOfMissingValues": 0, "NumberOfInstancesWithMissingValues": 0, "NumberOfNumericFeatures": 0, "NumberOfSymbolicFeatures": 37, "PercentageOfSymbolicFeatures": 100, "AutoCorrelation": 0.4777388694347174, "PercentageOfNumericFeatures": 0, "PercentageOfMissingValues": 0, "PercentageOfInstancesWithMissingValues": 0, "PercentageOfBinaryFeatures": 94.5945945945946, "NumberOfBinaryFeatures": 35, "MinorityClassSize": 956, "MinorityClassPercentage": 47.8, "MajorityClassSize": 1044, "MajorityClassPercentage": 52.2, "Dimensionality": 0.0185 }, "tags": [], "features": [ { "name": "class", "index": "36", "type": "nominal", "distinct": "2", "missing": "0", "target": "1", "distr": [ [ "won", "nowin" ], [ [ "1044", "0" ], [ "0", "956" ] ] ] }, { "name": "reskr", "index": "19", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "156", "140" ], [ "888", "816" ] ] ] }, { "name": "reskd", "index": "18", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "9", "7" ], [ "1035", "949" ] ] ] }, { "name": "rimmx", "index": "20", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "368", "0" ], [ "676", "956" ] ] ] }, { "name": "rkxwp", "index": "21", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "239", "145" ], [ "805", "811" ] ] ] }, { "name": "rxmsq", "index": "22", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "36", "76" ], [ "1008", "880" ] ] ] }, { "name": "simpl", "index": "23", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "405", "354" ], [ "639", "602" ] ] ] }, { "name": "skach", "index": "24", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "1", "3" ], [ "1043", "953" ] ] ] }, { "name": "skewr", "index": "25", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "707", "671" ], [ "337", "285" ] ] ] }, { "name": "skrxp", "index": "26", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "27", "75" ], [ "1017", "881" ] ] ] }, { "name": "spcop", "index": "27", "type": "nominal", "distinct": "1", "missing": "0", "distr": [ [ "t", "f" ], [ [ "0", "0" ], [ "1044", "956" ] ] ] }, { "name": "stlmt", "index": "28", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "0", "31" ], [ "1044", "925" ] ] ] }, { "name": "thrsk", "index": "29", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "43", "35" ], [ "1001", "921" ] ] ] }, { "name": "wkcti", "index": "30", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "233", "124" ], [ "811", "832" ] ] ] }, { "name": "wkna8", "index": "31", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "11", "105" ], [ "1033", "851" ] ] ] }, { "name": "wknck", "index": "32", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "223", "552" ], [ "821", "404" ] ] ] }, { "name": "wkovl", "index": "33", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "636", "611" ], [ "408", "345" ] ] ] }, { "name": "wkpos", "index": "34", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "826", "635" ], [ "218", "321" ] ] ] }, { "name": "wtoeg", "index": "35", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "n", "t", "f" ], [ [ "787", "730" ], [ "257", "226" ], [ "0", "0" ] ] ] }, { "name": "bxqsq", "index": "9", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "146", "459" ], [ "898", "497" ] ] ] }, { "name": "bknwy", "index": "1", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "70", "70" ], [ "974", "886" ] ] ] }, { "name": "bkon8", "index": "2", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "26", "56" ], [ "1018", "900" ] ] ] }, { "name": "bkona", "index": "3", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "107", "93" ], [ "937", "863" ] ] ] }, { "name": "bkspr", "index": "4", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "331", "331" ], [ "713", "625" ] ] ] }, { "name": "bkxbq", "index": "5", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "560", "356" ], [ "484", "600" ] ] ] }, { "name": "bkxcr", "index": "6", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "312", "433" ], [ "732", "523" ] ] ] }, { "name": "bkxwp", "index": "7", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "134", "295" ], [ "910", "661" ] ] ] }, { "name": "blxwp", "index": "8", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "349", "388" ], [ "695", "568" ] ] ] }, { "name": "bkblk", "index": "0", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "117", "115" ], [ "927", "841" ] ] ] }, { "name": "cntxt", "index": "10", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "488", "371" ], [ "556", "585" ] ] ] }, { "name": "dsopp", "index": "11", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "109", "94" ], [ "935", "862" ] ] ] }, { "name": "dwipd", "index": "12", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "g", "l" ], [ [ "283", "336" ], [ "761", "620" ] ] ] }, { "name": "hdchk", "index": "13", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "0", "12" ], [ "1044", "944" ] ] ] }, { "name": "katri", "index": "14", "type": "nominal", "distinct": "3", "missing": "0", "distr": [ [ "b", "n", "w" ], [ [ "48", "93" ], [ "775", "797" ], [ "221", "66" ] ] ] }, { "name": "mulch", "index": "15", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "13", "82" ], [ "1031", "874" ] ] ] }, { "name": "qxmsq", "index": "16", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "30", "28" ], [ "1014", "928" ] ] ] }, { "name": "r2ar8", "index": "17", "type": "nominal", "distinct": "2", "missing": "0", "distr": [ [ "t", "f" ], [ [ "650", "726" ], [ "394", "230" ] ] ] } ], "nr_of_issues": 0, "nr_of_downvotes": 0, "nr_of_likes": 0, "nr_of_downloads": 0, "total_downloads": 0, "reach": 0, "reuse": 0, "impact_of_reuse": 0, "reach_of_reuse": 0, "impact": 0 }