Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

specifying random columns in numpy

import pandas as pd  
import numpy as np

cols = [0, 1]
cols.extend(np.arange(10, df.shape[1]))
df.iloc[:,cols]
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #random #columns #numpy
ADD COMMENT
Topic
Name
2+6 =