Groups | Search | Server Info | Login | Register
Groups > comp.soft-sys.math.mathematica > #16812
| Path | csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!news.glorb.com!news-out.readnews.com!news-xxxfer.readnews.com!nx01.iad01.newshosting.com!newshosting.com!newspump.sol.net!post2.nntp.sol.net!posts.news.twtelecom.net!nnrp3.twtelecom.net!not-for-mail |
|---|---|
| From | Alexei Boulbitch <Alexei.Boulbitch@iee.lu> |
| Newsgroups | comp.soft-sys.math.mathematica |
| Subject | Re: Simple list question |
| Date | Wed, 16 Apr 2014 07:39:30 +0000 (UTC) |
| Sender | steve@smc.vnet.net |
| Approved | Steven M. Christensen <steve@smc.vnet.net>, Moderator |
| Message-ID | <lilc3i$qk0$1@smc.vnet.net> (permalink) |
| Lines | 55 |
| Organization | Time-Warner Telecom |
| NNTP-Posting-Date | 16 Apr 2014 07:45:34 GMT |
| NNTP-Posting-Host | fac608f9.news.twtelecom.net |
| X-Trace | DXC=ZaKf5RL0kFWc2Q2mco@>IVC_A=>8kQj6];[h;PUXBgbTPm3bW^Q9cmVEFiONJ7[GoVaJiaDdC^]l_ |
| X-Complaints-To | abuse@twtelecom.net |
| Xref | csiph.com comp.soft-sys.math.mathematica:16812 |
Show key headers only | View raw
pcin = 2;
pcex = 3; (*pcin and pcex can have various small values *)
coin = Table[{10 RandomReal[], 10 RandomReal[]}, {pcin}]
coex = Table[{3 RandomReal[], 3 RandomReal[]}, {pcex}]
cobo = Append[coin, coex]
gives, typically,
{{0.288346, 3.57763}, {1.7335, 8.69666}}
{{0.179831, 1.35324}, {0.927483, 0.931586}, {1.76338, 2.45073}}
{{0.288346, 3.57763}, {1.7335,
8.69666}, {{0.179831, 1.35324}, {0.927483, 0.931586}, {1.76338,
2.45073}}}
What I want is a series of x,y coordinates with no extra nesting:
{{0.288346, 3.57763}, {1.7335,
8.69666}, {0.179831, 1.35324}, {0.927483, 0.931586}, {1.76338,
2.45073}}
I'm embarrassed to admit that I can't find how to do this.
Please email me. Thank you.
Hi, you need Join instead of Append:
pcin = 2;
pcex = 3;(*pcin and pcex can have various small values*)coin =
Table[{10 RandomReal[], 10 RandomReal[]}, {pcin}];
coex = Table[{3 RandomReal[], 3 RandomReal[]}, {pcex}];
cobo = Join[coin, coex]
{{5.32716, 5.67691}, {0.325954, 1.69115}, {1.9243, 1.15678}, {1.23113,
1.97135}, {0.844278, 2.93468}}
Have fun, Alexei
Alexei BOULBITCH, Dr., habil.
IEE S.A.
ZAE Weiergewan,
11, rue Edmond Reuter,
L-5326 Contern, LUXEMBOURG
Office phone : +352-2454-2566
Office fax: +352-2454-3566
mobile phone: +49 151 52 40 66 44
e-mail: alexei.boulbitch@iee.lu
Back to comp.soft-sys.math.mathematica | Previous | Next | Find similar
Re: Simple list question Alexei Boulbitch <Alexei.Boulbitch@iee.lu> - 2014-04-16 07:39 +0000
csiph-web