Comments (4)
Ok I will look into a PR. For now I have just created my own Writer class, but of course this can be an issue if the package gets updated down the line :) I can perhaps add a check to ensure that it cannot start with those special as that is not allowed.
I will use this as a guide https://www.ibm.com/docs/en/spss-statistics/28.0.0?topic=SSLVMB_28.0.0/spss/base/syn_variables_variable_names.htm
from spss.
The $, #, and @ are special characters if they are written in a specific position, but they can also be used as part of the name if not. I think they are excluded here for simplicity. The reader must read it (otherwise we won't be able to read some files), but nothing forces the writer to allow it, since you can control how the file will be written. So I don't have a firm position on allowing the writer to use it or not. If you want that possibility to be included, please create a PR for that. If it doesn't affect anything else and the resulting file can be read, I don't see why it can't be merged.
from spss.
I will also suggest replacing A-Za-z
with \w
as that should allow any word character (eg. æøΓ₯ from the danish alphabet)
^(?!#)[\w0-9_\.#\x{4e00}-\x{9fa5}]+$
from spss.
Yes is the same, if is tested and we can write special characters without a problem, i don't see why not. This is allowed by the sav file specification. Just take care to not allow the inclusion of $, # in the first position and follow the that rules you linked.
from spss.
Related Issues (20)
- variable value label incomplete
- SPSS can't open files that have a variable with a width of 256 or greater. HOT 2
- Writer is taking a very long time to write a reasonable amount of data. HOT 1
- Variables with labels longer than 255 characters cause the program to hang in infinit while loop. HOT 5
- DATETIME fields can break subsequent numerical fields with value labels HOT 3
- extra string variables added when previous variable exceds 8 HOT 2
- Empty file in IBM SPSS when string in variable->data has length over 254 chars
- Read/Write the data on demand by case (row). HOT 1
- PSPP can not read the generated sav file HOT 5
- Writer problem
- Unable to save a value of 0 for FORMAT_TYPE_F variables. It gets written as a blank value every time. No luck using the values array. HOT 1
- PSPP error / SPSS crash on exported sav file HOT 1
- Warning for every fields on pspp "Warning: v00001 listed in very long string record with width 0032, which requires only one segment" HOT 3
- Need help πππ HOT 1
- Column format HOT 1
- "message": "unpack(): Type i: not enough input, need 4, have 0", HOT 4
- When values contain letters, numbers, and Chinese, there will be garbled code HOT 1
- Getting it to work with multibyte names HOT 11
- Speed up file creation HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from spss.