Skip to content

Commit 36e09ee

Browse files
committed
Remove MATLAB examples and references to API docs
1 parent 4e52322 commit 36e09ee

File tree

6 files changed

+33
-119
lines changed

6 files changed

+33
-119
lines changed

docs/src/compute/make.md

Lines changed: 4 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,7 @@ entered using the `insert` method directly.
99
[Automation](../tabletiers#automation-imported-and-computed).
1010

1111
The `make` method receives one argument: the *key*, which represents the upstream table
12-
entries that need populating. The `key` is a `dict` or `struct` in Python and Matlab,
13-
respectively.
12+
entries that need populating. The `key` is a `dict` in Python.
1413

1514
A `make` function should do three things:
1615

@@ -30,20 +29,6 @@ the class method called to run the `make` method on all relevant keys[^2].
3029
[^2]: For information on reprocessing keys that resulted in an error, see information
3130
on the [Jobs table](../../ref-integrity/distributed-computing).
3231

33-
=== "Python"
34-
35-
``` python
36-
Segmentation.populate()
37-
```
38-
39-
=== "Matlab"
40-
41-
In Matlab, the `key` is a `struct`.
42-
``` matlab
43-
populate(Segmentation)
44-
```
45-
46-
For more information on the `populate` options in each language, please visit the
47-
[Python and Matlab](../../../) documentation pages.
48-
49-
<!-- TODO: Replace above with respective links when live -->
32+
``` python
33+
Segmentation.populate()
34+
```

docs/src/design/diagrams.md

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@ some minor departures fom this standard.
66

77
Here, tables are depicted as nodes and [dependencies](../dependencies) as directed edges
88
between them. The `draw` method plots the graph, with many other methods (
9-
[Python](https://datajoint.com/docs/core/datajoint-python/latest/api/datajoint/diagram/),
10-
[Matlab](https://github.com/datajoint/datajoint-matlab/blob/master/%2Bdj/ERD.m)) to
9+
[Python](https://datajoint.com/docs/core/datajoint-python/latest/api/datajoint/diagram/)) to
1110
save or adjust the output.
1211

1312
Because DataJoint pipelines are directional (see [DAG](../../../glossary#dag)), the
@@ -23,8 +22,7 @@ DataJoint uses the following conventions:
2322
- [Tables](../table-definitions) are indicated as nodes in the graph. The
2423
corresponding class name is indicated by each node.
2524

26-
- [Table type](../../reproduce/table-tiers) is indicated by colors and symbols, with some
27-
differences across Python and Matlab:
25+
- [Table type](../../reproduce/table-tiers) is indicated by colors and symbols:
2826

2927
- **Lookup**: gray, rectangle or asterisk
3028

@@ -75,6 +73,3 @@ Here, we see ...
7573
6. Several Computed tables: *Segmentation*, *Trace*, and *RF*
7674

7775
7. A part table: *Field*
78-
79-
For examples calling `Diagram` in Python and Matlab, please visit the documentation for
80-
the respective API.

docs/src/design/tables/tiers.md

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,7 @@ Lookup tables contain basic facts that are not specific to an experiment and are
3232
persistent. In GUIs, lookup tables are often used for drop-down menus or radio buttons.
3333
In Computed tables, the contents of Lookup tables are often used to specify alternative
3434
methods for computations. Unlike Manual tables, Lookup tables can specify contents in
35-
the schema definition. For syntax, please visit the
36-
[Python](https://datajoint.com/docs/core/datajoint-python/) and
37-
[Matlab](https://datajoint.com/docs/core/datajoint-matlab/) documentation pages.
35+
the schema definition.
3836

3937
Lookup tables are especially useful for entities with many unique features. Rather than
4038
adding many primary keys, this information can be retrieved through an index. For an

docs/src/manipulation/insert.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,6 @@ call.
4949
data = query.fetch()
5050
```
5151

52-
For more examples in Python or Matlab, please visit the respective API documentation.
53-
5452
## Drop
5553

5654
The `drop` method completely removes a table from the database, including its
@@ -78,4 +76,3 @@ dj.Diagram(schema).draw()
7876
```
7977

8078
For more information about diagrams, see [this article](../../getting-started/diagrams).
81-
For more examples in Python or Matlab, please visit the respective API documentation.

docs/src/query/fetch.md

Lines changed: 25 additions & 76 deletions
Original file line numberDiff line numberDiff line change
@@ -10,53 +10,29 @@
1010
For example, if given a `Session` table, you can
1111
create a query object to retrieve its entire contents as follows:
1212

13-
=== "Python"
14-
15-
``` python
16-
query = Session()
17-
```
18-
19-
=== "Matlab"
20-
21-
``` matlab
22-
query = Session;
23-
```
13+
``` python
14+
query = Session()
15+
```
2416

2517
More generally, a query object may be formed as a **query expression**
2618
constructed by applying [operators](./operators.md) to other query objects.
2719

2820
For example, the following query retrieves information about all
2921
experiments and scans for mouse 001:
3022

31-
=== "Python"
32-
33-
``` python
34-
query = Session * Scan & 'animal_id = 001'
35-
```
36-
37-
Note that for brevity, query operators can be applied directly to class, as
38-
`Session` instead of `Session()`.
39-
40-
=== "Matlab"
23+
``` python
24+
query = Session * Scan & 'animal_id = 001'
25+
```
4126

42-
``` matlab
43-
query = Session * Scan & 'animal_id = 001';
44-
```
27+
Note that for brevity, query operators can be applied directly to class, as
28+
`Session` instead of `Session()`.
4529

4630
Alternatively, we could query all scans with a sample rate over 1000, and preview the
4731
contents of the query simply displaying the object.
4832

49-
=== "Python"
50-
51-
``` python
52-
Scan & 'sample_rate > 1000'
53-
```
54-
55-
=== "Matlab"
56-
57-
``` matlab
58-
Session * Scan & 'sample_rate > 1000';
59-
```
33+
``` python
34+
Scan & 'sample_rate > 1000'
35+
```
6036

6137
The above command shows the following table:
6238

@@ -81,25 +57,13 @@ Once the desired query object is formed, the query can be executed using its [fe
8157
(./fetch) methods. To **fetch** means to transfer the data represented by the query
8258
object from the database server into the workspace of the host language.
8359

84-
=== "Python"
85-
86-
```python
87-
query = Scan & 'sample_rate > 1000'
88-
s = query.fetch()
89-
```
90-
91-
Here fetching from the `query` object produces the NumPy record array
92-
`s` of the queried data.
60+
```python
61+
query = Scan & 'sample_rate > 1000'
62+
s = query.fetch()
63+
```
9364

94-
=== "Matlab"
95-
96-
``` matlab
97-
query = Session * Scan & 'sample_rate > 1000';
98-
s = query.fetch();
99-
```
100-
101-
Here fetching from the `query` object produces the struct array `s` of
102-
the queried data.
65+
Here fetching from the `query` object produces the NumPy record array
66+
`s` of the queried data.
10367

10468
## Checking for entities
10569

@@ -109,31 +73,16 @@ returned. It can be useful to know the number of entities returned by a query, o
10973
whether a query will return any entities at all, without having to fetch all the data
11074
themselves.
11175

112-
=== "Python"
113-
114-
The `bool` function applied to a query object evaluates to `True` if the
115-
query returns any entities and to `False` if the query result is empty.
76+
The `bool` function applied to a query object evaluates to `True` if the
77+
query returns any entities and to `False` if the query result is empty.
11678

117-
The `len` function applied to a query object determines the number of
118-
entities returned by the query.
79+
The `len` function applied to a query object determines the number of
80+
entities returned by the query.
11981

120-
``` python
121-
# number of sessions since the start of 2018.
122-
n = len(Session & 'session_date >= "2018-01-01"')
123-
```
124-
125-
=== "Matlab"
126-
127-
The `exists` method applied to a query object evaluates to `true` if the
128-
query returns any entities and to `false` if the query result is empty.
129-
130-
The `count` method applied to a query object determines the number of
131-
entities returned by the query.
132-
133-
``` matlab
134-
% number of ephys sessions since the start of 2018.
135-
n = count(ephys.Session & 'session_date >= "2018-01-01"')
136-
```
82+
``` python
83+
# number of sessions since the start of 2018.
84+
n = len(Session & 'session_date >= "2018-01-01"')
85+
```
13786

13887
## Normalization in queries
13988

docs/src/query/operators.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -120,9 +120,6 @@ The condition `cond` may be one of the following:
120120
- a `Not` object
121121
- a query expression
122122

123-
For more examples on each of these in Python and Matlab, please visit the documentation
124-
for the respective API.
125-
126123
??? Warning "Permissive Operators"
127124

128125
To circumvent compatibility checks, DataJoint offers permissive operators for
@@ -144,9 +141,6 @@ another the coordinator, both referencing the common personnel pool.
144141
3. Projection can also perform calculations (as available in
145142
[MySQL](https://dev.mysql.com/doc/refman/5.7/en/functions.html)) on a single attribute.
146143

147-
For examples of each of these in Python and Matlab, please visit the documentation for
148-
the respective API.
149-
150144
## Aggr
151145

152146
**Aggregation** is a special form of `proj` with the added feature of allowing
@@ -156,8 +150,7 @@ the respective API.
156150
in the matching entities of `other`.
157151

158152
Aggregation functions include `count`, `sum`, `min`, `max`, `avg`, `std`, `variance`,
159-
and others. For examples in Python and Matlab, please visit the documentation for the
160-
respective API.
153+
and others.
161154

162155
## Union
163156

@@ -221,9 +214,6 @@ Universal sets should be used sparingly when no suitable base tables already exi
221214
some cases, defining a new base table can make queries clearer and more semantically
222215
constrained.
223216

224-
For examples in Python and Matlab, please visit the documentation for the respective
225-
API.
226-
227217
The examples below will use the table definitions in [table tiers](../../reproduce/table-tiers).
228218

229219
<!-- ## Join appears here in the general docs -->

0 commit comments

Comments
 (0)