Skip to content

hvcat doc example fixed #13566

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Oct 13, 2015
Merged

hvcat doc example fixed #13566

merged 3 commits into from
Oct 13, 2015

Conversation

mbeltagy
Copy link
Contributor

hvcat doc example was not working
I changed it to one that does.

hvcat doc example was not working 
I changed it to one that does.
@tkelman
Copy link
Contributor

tkelman commented Oct 12, 2015

Note that the docstrings in the file you edited are auto-generated. The same change would also need to be made at the source for the docstring,

Horizontal and vertical concatenation in one call. This function is called for block matrix syntax. The first argument specifies the number of arguments to concatenate in each block row. For example, `[a b;c d e]` calls `hvcat((2,3),a,b,c,d,e)`.

@tkelman tkelman added the docs This change adds or pertains to documentation label Oct 12, 2015
@dpsanders
Copy link
Contributor

Probably the example would be clearer with a 2x3 matrix, as was originally (presumably) intended:

julia> a, b, c, d, e, f = 1, 2, 3, 4, 5, 6
(1,2,3,4,5,6)

julia> [a b c; d e f]
2x3 Array{Int64,2}:
 1  2  3
 4  5  6

This can then be a doctest.

Removed test for a non-working example and added clearer doctest example instead.
@mbeltagy
Copy link
Contributor Author

I fixed that now with a couple of clear doctest examples in my last commit.

2x3 Array{Int64,2}:
1 2 3
4 5 6

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please remove the trailing whitespace from here and 3810, and if you've got a local source build it would also be handy if you could run make && usr/bin/julia doc/genstdlib.jl on this branch to propagate these changes into the RST.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I followed your instructions. The latest commit should be good.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks!

jakebolewski added a commit that referenced this pull request Oct 13, 2015
@jakebolewski jakebolewski merged commit 582af41 into JuliaLang:master Oct 13, 2015
tkelman pushed a commit that referenced this pull request Oct 31, 2015
hvcat doc example was not working
I changed it to one that does.
(cherry picked from commit 3d132a9)
ref #13566
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs This change adds or pertains to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants