Skip to content
Snippets Groups Projects
Commit 0ddd0494 authored by Richter, Manuela's avatar Richter, Manuela
Browse files

in Funktion Tagplot Cosinus-Funktion dem Diagramm hinzugefügt

parent 77d5b840
Branches
Tags
1 merge request!12v.0.1 for alpha release
......@@ -15,8 +15,8 @@ from numpy import random
import h5py as h5
import matplotlib.pyplot as plt
plt.style.use('fcn_help/FST.mplstyle')
#%matplotlib qt
%matplotlib inline
%matplotlib qt
#%matplotlib inline
from FST_colors import Colors
from TagPlot import TagPlot
#%% Pfade hinzufügen
......@@ -43,12 +43,10 @@ color_list = colors.get_color_names()
# Plot erstellen
color1 = colors.get_rgb('black')
color2 = colors.get_rgb('yellow')
#fig = plt.figure()
fig = plt.figure()
plt.plot(x,y, color=color1)
plt.plot(x,y_2, color= color2)
plt.draw()
fig = plt.gcf()
#print(type(Figure1))
......@@ -56,10 +54,12 @@ fig = plt.gcf()
#figs.show()
numbers = plt.get_fignums()
labels = plt.get_figlabels()
print(numbers)
print(labels)
# numbers = plt.get_fignums()
# labels = plt.get_figlabels()
# print(numbers)
# print(labels)
# plt.draw()
# plot taggen
......
......@@ -5,6 +5,11 @@ Created on Tue Jul 27 10:50:20 2021
@author: Richter
"""
import matplotlib.pyplot as plt
plt.style.use('fcn_help/FST.mplstyle')
#%matplotlib qt
#%matplotlib inline
import numpy as np
from FST_colors import Colors
def TagPlot(figs,prefix):
......@@ -16,16 +21,17 @@ def TagPlot(figs,prefix):
ID = prefix + '_' +'Test'
rect = l, b, w, h
figs.add_axes(rect)
#n_axes = plt.getp(Axes)
#print(n_axes)
# ylim = plt.get(axes, 'YLim')
#print("Funktion TagPlot aufgerufen")
#print(type(figs))
# figs.add_subplot(231)
#%%
b = figs.gca()
a = figs.get_axes()
print(a,b)
figs.set_label('Hallo')
x = np.linspace(0,10,100)
y_2 = np.cos(x) +2
colors = Colors()
plt.plot(x,y_2, color= colors.get_rgb('blue'))
plt.draw()
# Titel über get Funktion anpassen
# figs ist ein Objekt einer bestimmten Klasse
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment