Jump to content

User:Lone Skeptic/Sandbox

From Wikipedia, the free encyclopedia

This sandbox is an opportunity to play around with some basic style things.

Pages you want to look at[edit]

  • CCP, disambiguation page with many broken links, bad organization
 Done 04:01, 10 August 2008 (UTC)
  • SKU, merger proposed but no discussion
 Done (commented at Talk: Stock-keeping unit#Merger proposal) 18:02, 10 August 2008 (UTC)

Styles[edit]

Now let's try with some subsections.

Regular text[edit]

Hello, world

Bold text[edit]

Hello, world

Italicized text[edit]

Hello, world

Hyperlinked text[edit]

Hello, world

Bold, italicized hyperlink[edit]

Hello, world

Source[edit]

How about some MATLAB?[1]

function bval = blend(varargin)

% Approximates the value of a discretely defined function between points.
%
% Syntax is approx_value = blend(xvector,yvector,x[,supresswarning])
%
% A nonzero fourth argument will supress warning messages.  This is useful
% if iterative extrapolation is desired.

% Check input arguments
if length(varargin) < 3
    error('Too few input arguments; syntax is approx_value = blend(xvector,yvector,x[,supresswarning])');
elseif length(varargin) > 4
    error('Too many input arguments; syntax is approx_value = blend(xvector,yvector,x[,supresswarning])');
end

% Give inputs working names, sort x vectors, match y values
[x,sortvec] = sort(varargin{1});
y = varargin{2}(sortvec);
xreq = varargin{3};

% Call bracket to find closest two points
[lo,hi] = bracket(x,xreq);

% Check domain and possibly give warning
if (xreq < x(lo) || xreq > x(hi)) && length(varargin) ~= 4
    warning('Requested value is outside the domain of given vector; extrapolating (x = %d)',xreq);
end

% Use straight line approximation to find value
slope = (y(hi)-y(lo))/(x(hi)-x(lo));
bval = y(lo)+slope*(xreq-x(lo));

return

A table[edit]

A test table
This is the second column This is the third column
This is the first row Cell 1 Cell 2
This is the second row Cell 3 Cell 4
This is the third row
Used as a picture caption

Why not just put all of the text "after" the floating table. This way it is incorporated seamlessly into the section. This text is all after the table, but it should be inserted to the left and fit to the table. Of course there is a lot of table, so how about bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla.

I figured out that I need to use this: "{{-}}", to prevent the next section from wrapping around the table as well. I couldn't find an explanation.

A formula[edit]

The formula for aspect ratio is:

A test[edit]

Can you use a citation tag outside a <ref> tag? Let's see...

Method of Anisotropically Etching Silicon {{citation}}: Unknown parameter |country-code= ignored (help); Unknown parameter |inventor-first= ignored (help); Unknown parameter |inventor-last= ignored (help); Unknown parameter |inventor2-first= ignored (help); Unknown parameter |inventor2-last= ignored (help); Unknown parameter |issue-date= ignored (help); Unknown parameter |patent-number= ignored (help)

Apparently yes. Another test:

The best I could get w/ {{Citation}} template:

Planque, Stephanie; et al. (2007), "Characterization of gp120 Hydrolysis by IgA Antibodies from Humans without HIV Infection", AIDS Research and Human Retroviruses, vol. 23, no. 12, pp. 1541–1554 {{citation}}: Explicit use of et al. in: |first= (help)

My preference:

Planque, Stephanie et al., "Characterization of gp120 Hydrolysis by IgA Antibodies from Humans without HIV Infection," AIDS Research and Human Retroviruses, 23(12): 1541-1554, December 2007.

References[edit]

  1. ^ G, M. Not a Real Book.