« first day (4309 days earlier)   

00:02
0
Q: Optimize this code in python

phyAlphI am trying to implement a CART (classification and regression tree) algorithm in python. When it comes to find the best split I have this code: for col in X.shape[1]: sorted_indices = np.argsort(features[:, col]) sorted_features = features[sorted_indices, col] sorted_target = target[sorted_indic...

00:22
REFRESH! There are 5057 unanswered questions (93.4769 answered)
@CaptainObvious @toolic New users can't see VTC, it might help to down vote as well. Since the title was also off-topic I added a link to how to ask.
 
2 hours later…
02:07
If you have working code that you're looking to have peer-reviewed for improvements, your question belongs on Code Review instead, which was created specifically for that purpose. This site is for specific questions related to actual problems that you're having with code or use of a programmer's tool (IDE, compiler, etc.). — Ken White 12 secs ago

« first day (4309 days earlier)