Scilab Website | Contribute with GitLab | Mailing list archives | ATOMS toolboxes
Scilab Online Help
6.1.1 - 日本語

Change language to:
English - Français - Português - Русский

Please note that the recommended version of Scilab is 2025.0.0. This page might be outdated.
See the recommended documentation of this function

Scilabヘルプ >> Graphics > axes_operations > newaxes

newaxes

新しいAxesエンティティを作成

呼び出し手順

a = newaxes()
a = newaxes(h)

引数

h

Optional handle of the graphic parent of the new axes, of type Figure or Uicontrol of style Frame. By default, the current figure is used.

a

ハンドル, 新たに作成された Axesエンティティのハンドル

説明

newaxes() は,カレントの図に新しいAxes エンティティ( graphics_entities参照)を 作成する際に使用されます. このエンティティのプロパティはdefault_axes (gda参照) から継承されます.

clf()
a1 = newaxes();
a1.axes_bounds = [0,0,1.0,0.5];
t = 0:0.1:20;
plot(t,acosh(t),'r')
a2 = newaxes();
a2.axes_bounds = [0,0.5,1.0,0.5];
x = 0:0.1:4;
plot(x,sinh(x))
legend('sinh')

sca(a1); //最初の軸をカレントとする
plot(t,asinh(t),'g')
legend(['acosh','asinh'])

The following example uses newaxes(h)

// Create a new figure
f = figure("layout", "gridbag", ...
    "toolbar", "none", ...
    "menubar", "none", ...
    "backgroundcolor", [1 1 1]);

// Create the frames where each graph is put
c = createConstraints("gridbag", [1 1 1 1], [1 1], "both");
top_left = uicontrol(f, "style", "frame","constraints", c);

c.grid = [2 1 1 1];
top_right = uicontrol(f, "style", "frame", "constraints", c);

c.grid = [1 2 2 2];
bottom = uicontrol(f, "style", "frame", "constraints", c);

// Create the axes in each frame
a_tl = newaxes(top_left);
a_tr = newaxes(top_right);
a_bt = newaxes(bottom);

// Plot in the frames
X = (1:100) ./ 50;
plot(a_tl, X, X, "r");
plot(a_tr, X, cos(2 * %pi * 3 * X), "g");
plot(a_bt, X, exp(X), "b");

title(a_tl, "a line");
title(a_tr, "a cosine");
title(a_bt, "the exponential");

参照

  • Multiscaled plots — How to set several axes for one curve or for curves with distinct scales
  • subplot — グラフィックウインドウをサブウインドウの行列に分割する
  • xsetech — プロット時にグラフィックウインドのサブウインドウを設定
  • gda — デフォルトの軸(axes)のハンドルを取得.
  • sca — カレントの軸のエンティティを設定する

履歴

バージョン記述
5.5.0 newaxes(h) can target a uicontrol frame or a given figure.
Report an issue
<< isoview axes_operations plotframe >>

Copyright (c) 2022-2024 (Dassault Systèmes)
Copyright (c) 2017-2022 (ESI Group)
Copyright (c) 2011-2017 (Scilab Enterprises)
Copyright (c) 1989-2012 (INRIA)
Copyright (c) 1989-2007 (ENPC)
with contributors
Last updated:
Mon Jan 03 14:37:52 CET 2022