semvec/pypi-packages huggingface dataset:
stns 0.0.2
A collection of scripts used in the Nusbaum Lab for data analysis, modeling, and visualization
Requires Python: >=3.6.0


# stns
stns is a collection of various scripts used in the Nusbaum lab's python analysis.

How do I use stns?
-------------
stns is used primarily for spike detection and data visualizing, an example of loading the main GUI is shown below.
Various plotting functions can be found in the module plot.

```python
from stns import SpikeDetectionGUI

# Launch a spike detection gui
dir_name = '/Users/loganfickling/Downloads/Lingli_Data_Transferred/Data/05-22-07/'
f_name = 'b0p057-cond 2LPG killed-ions stim 3_6V 14hz-cogs off-LG PD LP_export.smr'
app = SpikeDetectionGUI(provided_path=dir_name + f_name) # Or don't pass a path and enter it manually
app.mainloop()

```
See the documentation for more examples, or in python call help(functionname) to pull up the docstrings of the relevant
function

stns is currently in development; some features have not yet been implemented and there may be bugs.
See 'Development status' below.

Requirements
------------
scipy

numpy

pandas

matplotlib

seaborn

pandastable

brian2

neo


Quick start
-----------

stns can be installed using pip:

    $ pip install stns

If you want to run the latest version of the code, you can install from git:

    $mkdir crabby
    $cd crabby
    $git clone https://github.com/LoganJF/stns.git .
    $python setup.py install


Development status
------------------
Beta testing currently 0.0.1
svgreplicate 0.1.1
Tool for batch modifying and replicating SVG-files
Requires Python: >=3.9,<4.0

# SVGReplicate 

Tool for batch modifying and replicating SVG files. 

## Installation 

Install from PyPI by running `pip install svgreplicate`.

## Usage

Create an SVG file, either by hand or with your favorite vector graphics tool, like [InkScape](https://inkscape.org):

```xml
<svg
    width="210mm"
    height="297mm" 
    id="svg" 
    version="1.1"
    xmlns="http://www.w3.org/2000/svg" >
    <g id="group1">
        <ellipse
            style="opacity:1;fill:#009bff"
            id="ellipse1"
            cx="0.0"
            cy="0.0"
            rx="10.0"
            ry="10.0" />
        <g id="group2" />
    <text id="text1">
        <tspan>First text</tspan>
        <tspan>Second text 
            <tspan>Nested text</tspan> 
        </tspan>
    </text>
    </g>
</svg>
```

Next, create a json with the replicas you want: 

```json
[
    {
        "filename": "example/replica1.svg", 
        "modifications": [
        	{"id": "ellipse1", "style": {"fill": "#000000", "display": "none"}},
        	{"id": "group2", "style": {"display": "none"}},
        	{"id": "text1", "text": "Hello, world!"}
        ]
    },
    {
        "filename": "example/replica2.svg",
        "modifications": [
                {"id": "ellipse1", "style": {"fill": "#ffffff", "display": "none"}},
                {"id": "group2", "style": {"display": "none"}},
                {"id": "text1", "text": "Here's Johnny!"}
        ]
    }
]
```

And finally, run the script:

```bash 
svgreplicate --filename path-to-svg-template.svg --replicas path-to-replicas-config.json 
```

You now have 2 files in the example folder, based on the template, with the specified modifications. 

## Backlog 

In future, I'd like to add at least the functionality for automatically rendering to PNG.