Exemple #1
0
def test_simple_plot():
    """Test as simple map plot only making an instance++ and plot."""

    mysurf = RegularSurface()
    mysurf.from_file(SFILE1)

    # just make the instance, with a lot of defaults behind the scene
    myplot = Map()
    myplot.canvas(title="My o my")
    myplot.colormap = "gist_ncar"
    myplot.plot_surface(mysurf)

    myplot.savefig("TMP/map_simple.png")
Exemple #2
0
def test_perm_logarithmic_map():
    """Map with PERM, log scale."""

    mysurf = RegularSurface(SFILE2)

    myplot = Map()
    myplot.canvas(title="PERMX normal scale")
    myplot.colormap = "rainbow"
    myplot.plot_surface(mysurf,
                        minvalue=0,
                        maxvalue=6000,
                        xlabelrotation=45,
                        logarithmic=True)

    myplot.savefig(TD + "/permx_normal.png")
Exemple #3
0
def test_perm_logarithmic_map():
    """Map with PERM, log scale."""

    mysurf = RegularSurface(sfile2)

    myplot = Map()
    myplot.canvas(title='PERMX normal scale')
    myplot.colormap = 'gist_rainbow_r'
    myplot.plot_surface(mysurf,
                        minvalue=0,
                        maxvalue=6000,
                        xlabelrotation=45,
                        logarithmic=True)

    myplot.savefig(td + '/permx_normal.png')
Exemple #4
0
def test_more_features_plot():
    """Map with some more features added, such as label rotation."""

    mysurf = RegularSurface()
    mysurf.from_file(SFILE1)

    myfaults = Polygons(PFILE1)

    # just make the instance, with a lot of defaults behind the scene
    myplot = Map()
    myplot.canvas(title="Label rotation")
    myplot.colormap = "rainbow"
    myplot.plot_surface(mysurf,
                        minvalue=1250,
                        maxvalue=2200,
                        xlabelrotation=45)

    myplot.plot_faults(myfaults)

    myplot.savefig(TD + "/map_more1.png")
Exemple #5
0
def test_map_plot_with_points():
    """Test as simple map plot with underlying points."""

    mysurf = RegularSurface()
    mysurf.from_file(SFILE1)

    mypoints = Points()
    mypoints.from_surface(mysurf)

    df = mypoints.dataframe.copy()
    df = df[::20]
    mypoints.dataframe = df

    # just make the instance, with a lot of defaults behind the scene
    myplot = Map()
    myplot.canvas(title="My o my")
    myplot.colormap = "gist_ncar"
    myplot.plot_surface(mysurf)
    myplot.plot_points(mypoints)

    myplot.savefig("TMP/map_with_points.png")