In [1]:
#general imports
import matplotlib.pyplot as plt   
import pygslib
import numpy as np

#make the plots inline
%matplotlib inline



In [2]:
#get the data in gslib format into a pandas Dataframe
mydata= pygslib.gslib.read_gslib_file('../datasets/cluster.dat')

In [9]:
__inds = None
pygslib.plothtml.scatter2D(# data
              x= mydata['Xlocation'], 
              y= mydata['Ylocation'],
              z= mydata['Primary'],
              # vmin and max for formating               
              vmin=0.1, 
              vmax=30, 
              # parameters for color
              cmax = 'red', 
              cmin = 'blue', 
              cundef='grey', 
              cpalete_size=300, 
              ctransform = 'linear',
              #parameter for radii
              radii=0.5,  # to do, create gradtated radii
              # line color
              lcolor= 'black',
              # parameters for plot
              title='Scatterplot',
              TOOLS='crosshair,pan,wheel_zoom,box_zoom,reset,tap,previewsave,box_select,poly_select,lasso_select',
              xlabel='X',
              ylabel='Y',
              alpha=0.9,
              # call back variable
              outvar='__inds')

print ("*****************************************************")
print (" Select some datapoints, e.g. using the tool lasso ")
print ("*****************************************************")


*****************************************************
 Select some datapoints, e.g. using the tool lasso 
*****************************************************

In [10]:
# __ind 
mydata.iloc[list(__inds), :]


---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-10-4e2a6c94c4e3> in <module>()
      1 # __ind
----> 2 mydata.iloc[list(__inds), :]

TypeError: 'NoneType' object is not iterable

In [ ]: