I need to create a function or equation that will turn this input...
a = [True, False, True]
b = [[1, 2, 3], [4, 5, 6], [7, 8, 9]]
c = [[1, 3], [4, 6], [7, 9]]
numpy
solution
import numpy as np
a = np.array([True, False, True])
b = np.array([[1, 2, 3], [4, 5, 6], [7, 8, 9]])
b[:,a]
array([[1, 3],
[4, 6],
[7, 9]])