<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />Non riesco a capire come visualizzare una legenda nel mio grafico bivariante tramite OLE. C'è poca documentazione in JSL OLE (io sono l'unico a farlo?). Qualcuno può indicarmi la giusta direzione? Nello stato attuale, visualizzerà il grafico e il codice colore per colonna. Tutto quello che devo fare è visualizzare la legenda.
Ecco il mio codice (VBscript):
'Inizializza JMP
Dim MyJMP, JMPDoc, DT, DT2, WidthTable, FrameBox
Imposta MyJMP = CreateObject ("JMP.Application")
MyJMP.Visible = true
Imposta JMPDoc = MyJMP.OpenDocument ("MyFile.csv")
'Converti documento in datatable
Imposta DT = JMPDoc.GetDataTable
'Seleziona i dati della larghezza (alta e bassa)
DT.SelectRowsWhere "CHART_SUBSET", rowSelectEquals, rowSelectExtendCurrent, "TARGET = HIGH"
DT.SelectRowsWhere "CHART_SUBSET", rowSelectEquals, rowSelectExtendCurrent, "TARGET = LOW"
Imposta WidthTable = DT.subset
WidthTable.ColorByColumn ( "SPC_ENTITY")
WidthTable.MarkerByColumn ( "SPC_ENTITY")
'*************************
'Crea grafico bivariante
'*************************
Dim Biv
Imposta Biv = WidthTable.Document.CreateBivariate
Biv.LaunchAddY ( "SPC_CHART_VALUE")
Biv.LaunchAddX ( "SPC_TXN_DATE")
Biv.LaunchAddBy ( "SPC_CHART_SUBSET")
Biv.FitLine
Biv.Launch
FrameBox = Biv.GetGraphicItemByType ("frame box", 1)
Biv.FrameBoxAddGraphicsScript 1, "Legenda riga (: SPC_ENTITY)"
Biv.FrameBoxSetMarkerSize 1, 4
Ciao Maltman:
La funzione RunCommand () universale consente di eseguire facilmente tutto ciò che ti piace direttamente in JMP, ... e quindi se si cattura lo script, è facile inviarlo dal lato automazione, da VBA, o Perl, di Python, o R, ecc ...
Migliore,
-Opaco
Sottotitolo pubblico ()
'Inizializza JMP
Dim MyJMP, JMPDoc, DT, DT2, WidthTable, FrameBox
Imposta MyJMP = CreateObject ("JMP.Application")
MyJMP.Visible = True
Imposta JMPDoc = MyJMP.OpenDocument ("C: / temp / Big Class.jmp")
'Converti documento in datatable
Imposta DT = JMPDoc.GetDataTable ()
'Seleziona i dati della larghezza (alta e bassa)
DT.SelectRowsWhere "age", rowSelectEquals, rowSelectExtendCurrent, "12"
DT.SelectRowsWhere "age", rowSelectEquals, rowSelectExtendCurrent, "13"
Set WidthTable = DT.Subset ()
WidthTable.ColorByColumn ("nome")
WidthTable.MarkerByColumn ("sex")
'*************************
'Crea grafico bivariato
'*************************
Dim str As String
str = "Bivariate (" _
& "Y (: peso)," _
& "X (: altezza)," _
& "Adatta linea ({Colore linea ({213, 72, 87})})," _
& "SendToReport (" _
& "Dispatch (" _
& "{}," _
& "" "Bivar Plot" "," _
& "FrameBox", _
& "{Dimensioni indicatore (4), Legenda riga (" _
& "nome, colore (1), tema colore (" "JMP predefinito" ")," _
& "Indicatore (0)," _
& "Tema indicatore (" "" ")," _
& "Scala continua (0)," _
& "Scala inversa (0)," _
& "Righe escluse (0)" _
& ")}" _
& ")" _
& ")" _
& ");"
Debug.Print (str)
MyJMP.RunCommand (str)
End Sub
Sto ancora cercando un aiuto su questo se qualcuno può fornire qualche intuizione.
Ho provato qualcosa di simile ma non ha funzionato:
Biv.LaunchAddJSL "Legenda riga (: SPC_ENTITY, colore (1), Marker (1));"
Grazie