tuto000.py 467 Bytes
Newer Older
1
2
#!/usr/bin/env python

3
def script(with_print=False):
4

5
    import sys
6

7
    sys.path.append('../../')
8

9
    from myplotlib.mpl_toolbox import Ax2dPlots
10
    from myplotlib import EmptyFig
11

12
    rawdata = [0.1, 0.2, 0.4, 0.6, 1., 0.9, 1.2, 1.3, 1.2]
13

14
15
16
17
18
    fig = EmptyFig()
    fig.add_axes(Ax2dPlots(fig), 'ax1')
    fig.set_rawdata((rawdata,))

    if with_print:
19
        fig.print_to_file('./tuto000.png')
20
21
22
23
24

    return(fig)    

if __name__ == '__main__':
    script(True)