Adapting machine learning algorithms to handle clusters or batch effects within training datasets is important in various biological applications.Ensembling Random Forest learners trained on clusters in datasets with heterogeneous feature distributions improves accuracy and generalizability.The Cross-Cluster Weighted Forest approach shows significant benefits over the traditional Random Forest algorithm.The approach outperforms classic Random Forest in cancer molecular profiling and gene expression datasets.