I want to download a file with the extension .nb that was uploaded to a GitHub repository. However, it has a strange format that I can't get round and use it like the original. Here is a sample of what it looks like:
(*** Wolfram Notebook File ***)
(* http://www.wolfram.com/nb *)
(* CreatedBy='Mathematica 7.0' *)
(*CacheID: 234*)
(* Internal cache information:
NotebookFileLineBreakTest
NotebookFileLineBreakTest
NotebookDataPosition[ 145, 7]
NotebookDataLength[ 1053158, 18799]
NotebookOptionsPosition[ 1043705, 18664]
NotebookOutlinePosition[ 1044264, 18683]
CellTagsIndexPosition[ 1044221, 18680]
WindowFrame->Normal*)
(* Beginning of Notebook Content *)
Notebook[{
Cell[BoxData[
RowBox[{"(*",
RowBox[{"Import", " ", "data", " ", "from", " ",
RowBox[{"the", " ", ".", "csv"}]}], "*)"}]], "Input",
CellChangeTimes->{{3.8325121403603525\`*^9, 3.832512162342577*^9},
3.8338276384526296`*^9},
FontFamily->"Consolas",
FontWeight->"Normal",ExpressionUUID->"6e20bfb1-78fc-454a-85f3-fab3e1e1f609"],
Cell[BoxData[
RowBox[{
RowBox[{"s", "=",
RowBox[{
"Import", "[", "\"\<C:\\\\Users\\\\User\\\\Desktop\\\\data02.csv\>\"",
"]"}]}], ";"}]], "Input",
CellChangeTimes->{{3.831030550939706*^9, 3.831030563133726*^9}, {
3.83103080712603*^9, 3.8310308583911963\`*^9}, {3.8310332771328163\`*^9,
3.831033277194804*^9}, {3.8310363192249303\`*^9, 3.831036327345213*^9}, {
3.83330485714029*^9, 3.8333048619195776\`*^9}, 3.833829927653514*^9, {
3.833833840478625*^9, 3.833833846148329*^9}},
FontFamily->"Consolas",
FontWeight->"Bold",ExpressionUUID->"4af89285-72de-4b68-b0f1-ffa673886bec"],
(...)
I have looked into the link that is present in this sample, but couldn't find anything useful.
What should I do to recover its initial state. In other words, what can be done to reuse the functions and content that it had?
CodePudding user response:
That looks like the normal underlying code of a Mathematica notebook. If you copy the code into a plain text editor and save it with the extension .nb it should open normally in Mathematica.