projects
/
hooke.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
6b42cc2
)
(generalvclamp.py) now linefit_between accepts whatset
author
devicerandom
<devnull@localhost>
Tue, 3 Mar 2009 15:58:29 +0000
(15:58 +0000)
committer
devicerandom
<devnull@localhost>
Tue, 3 Mar 2009 15:58:29 +0000
(15:58 +0000)
generalvclamp.py
patch
|
blob
|
history
diff --git
a/generalvclamp.py
b/generalvclamp.py
index e200a59910bcd3bb643667073931fbb6941cbb9d..ebd3e084067377b7ebfe73c134f49f24e229cbc2 100644
(file)
--- a/
generalvclamp.py
+++ b/
generalvclamp.py
@@
-270,7
+270,7
@@
class generalvclampCommands:
self._send_plot([lineplot])
self._send_plot([lineplot])
- def linefit_between(self,index1,index2):
+ def linefit_between(self,index1,index2
,whatset=1
):
'''
Creates two vectors (xtofit,ytofit) slicing out from the
current return trace a portion delimited by the two indexes
'''
Creates two vectors (xtofit,ytofit) slicing out from the
current return trace a portion delimited by the two indexes
@@
-282,8
+282,8
@@
class generalvclampCommands:
(c) Marco Brucale, Massimo Sandal 2008
'''
# Translates the indexes into two vectors containing the x,y data to fit
(c) Marco Brucale, Massimo Sandal 2008
'''
# Translates the indexes into two vectors containing the x,y data to fit
- xtofit=self.plots[0].vectors[
1
][0][index1:index2]
- ytofit=self.plots[0].vectors[
1
][1][index1:index2]
+ xtofit=self.plots[0].vectors[
whatset
][0][index1:index2]
+ ytofit=self.plots[0].vectors[
whatset
][1][index1:index2]
# Does the actual linear fitting (simple least squares with numpy.polyfit)
linefit=[]
# Does the actual linear fitting (simple least squares with numpy.polyfit)
linefit=[]