       Show[list] does not work - details of the script

• To: mathgroup at smc.vnet.net
• Subject: [mg98375] Show[list] does not work - details of the script
• From: Venkatesh Ramakrishnan <venkatr at tifr.res.in>
• Date: Wed, 8 Apr 2009 05:02:58 -0400 (EDT)
• Organization: Tata Institute of Fundamental Research

Dear All

i am kind of newbie in Mathematica programming,
There are some errors which I am not able to troubleshoot...

I would be very thankful, if someone can look into it....

I have pasted the whole script and the errors-
Clear["Global` *"]
ClearSystemCache["Numeric"];
Clear[l];
plot1 = {};
plot2 = {};
myPlots = {};
\$RecursionLimit = 10000;
as = {};
lst = {};
hg = 0;
Clear[k];
Data = {};
dataFilenames1 = Flatten[Table[FileNames["*.new"], {1}]];
Data = Table[
ToString[
StringJoin["/home/venki/ten1/BMRB_files/",
ToString[dataFilenames1[[vh]]]]], {vh, 1, 100}];

Do[
ToString[Data[[m]]]
Clear[mat];
Clear[k];
Clear[l];
Clear[x];
Clear[z];
k = Import[ToString[Data[[m]]], "Table"];
Grid[k];
mat = k;
MatrixForm[mat];
l = Transpose[mat];
x = l[[1, All]];
z = l[[2, All]];

Clear[kj];
lst = {};
For[i = 1, i <= 220, i = i + 1,
If[x[[i]] == hg, lst = Append[{z[[i]]}, lst]]];
(*For[i=1,i<=220,i=i+1,If[MemberQ[lst,x[[i]]]==True &&x[[i]]==j \
,lst=Append[{z[[i]]},lst],Delete[lst,i]]];*)
kj = Flatten[lst];
x1 = kj[];
y1 = kj[];
y2 = kj[];

(*Print[MemberQ[kj,y2]]
If[MemberQ[kj,y2]== False,Print["you are great"],Print["You are \
still great"]]
If[MemberQ[kj,y2]-> False,Print["you are great"],Print["You are \
still great"]]*)

If[MemberQ[kj, x1] == True,
If[ MemberQ[kj, y2] == False,
plot1 = Flatten[Append[{ListPlot[{x1, y1}]}, plot1]]
, plot2 =
Flatten[Append[{ListPlot[{{x1, y1}, {x1, y2}}]}, plot2]];
]]
myPlots = Join[plot1, plot2];
, {m, 2}]
Show[plot2]

Errors and output

Part::partw: Part All of {} does not exist. >>
Part::partw: Part All of {} does not exist. >>
Part::partw: Part 4 of {}[[1,All]] does not exist. >>
General::stop: Further output of Part::partw will be suppressed during
this calculation. >>
Set::write: Tag Times in Null {} is Protected. >>
Set::write: Tag Times in Null {} is Protected. >>
Show::shx: No graphical objects to show. >>
Show[{}]

• Prev by Date: PlotLegends bug?
• Next by Date: Re: AMERICAN MATHEMATICAL MONTHLY -April 2009:Transformations Between
• Previous by thread: Re: PlotLegends bug?
• Next by thread: Re: Show[list] does not work - details of the script